~abentley/bzrtools/bzrtools.dev

« back to all changes in this revision

Viewing changes to fai/aba/commands/mcommit

  • Committer: Robert Collins
  • Date: 2005-09-13 12:39:26 UTC
  • mto: (147.2.6) (364.1.3 bzrtools)
  • mto: This revision was merged to the branch mainline in revision 324.
  • Revision ID: robertc@robertcollins.net-20050913123926-b72242bdacc1ae52
create the output directory

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh
 
2
## Copyright (C) 2004 Aaron Bentley
 
3
##
 
4
## See the file "COPYING" for further information about
 
5
## the copyright and warranty status of this work.
 
6
 
 
7
. "$abadir/aba-lib"
 
8
 
 
9
# executes the command ("$@" are the arguments after the command name)
 
10
cmd_exec()
 
11
{
 
12
  tla commit "$@"
 
13
  if [ $? -ne 0 ]; then
 
14
    exit;
 
15
  fi
 
16
  tv=$(tla tree-version)
 
17
  if [ $? -ne 0 ]; then
 
18
    exit;
 
19
  fi
 
20
  archive=$(tla parse-package-name --arch $tv)
 
21
  version=$(tla parse-package-name --package-version $tv)
 
22
  tla archive-mirror $archive $version
 
23
}
 
24
 
 
25
# one-liner description for aba help
 
26
cmd_desc()
 
27
{
 
28
    aba_desc $(basename $0) "commits and mirrors a revision"
 
29
}
 
30
 
 
31
# short help for aba command -h, --help
 
32
cmd_help()
 
33
{
 
34
    cat <<EOH
 
35
commits and mirrors a revision
 
36
usage: $abaname $(basename $0) [OPTIONS]
 
37
 
 
38
Accepts all commit options, but --dir should not be used, since mirroring
 
39
is done according to tree-version.
 
40
 
 
41
All revisions in the current project tree are mirrored, not only the one
 
42
committed.
 
43
EOH
 
44
}
 
45
 
 
46
# extended help for aba command -H or aba help command
 
47
cmd_ext_help()
 
48
{
 
49
    cat <<EOH
 
50
EOH
 
51
}       
 
52
 
 
53
aba_run "$@"
 
54
 
 
55
# arch-tag: mcommit by Aaron Bentley  (12:20 Feb 18 2004)