Revision 25694,
778 bytes
checked in by jdreed, 12 years ago
(diff) |
"then" does not terminate "if" blocks
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | # Usage: damove NEW_SUFFIX OLD_SUFFIX SOURCE_PACKAGE |
---|
4 | |
---|
5 | # Move the source package from the old suffix to the new suffix, where |
---|
6 | # a suffix is probably one of "", "-proposed", or "-development" |
---|
7 | # |
---|
8 | # This moves any source or binary package built from the source |
---|
9 | # package PACKAGE |
---|
10 | |
---|
11 | set -e |
---|
12 | |
---|
13 | . $(dirname "$0")/debian-versions.sh |
---|
14 | |
---|
15 | if [ "$#" -lt 3 ]; then |
---|
16 | echo "Usage: damove NEW_SUFFIX OLD_SUFFIX SOURCE_PACKAGE" >&2 |
---|
17 | exit 1 |
---|
18 | fi |
---|
19 | |
---|
20 | new_suffix="$1"; shift |
---|
21 | old_suffix="$1"; shift |
---|
22 | |
---|
23 | for pkg in "$@"; do |
---|
24 | dacopy "$new_suffix" "$old_suffix" "$pkg" |
---|
25 | if [ "$new_suffix" != "$old_suffix" ]; then |
---|
26 | daremove "$old_suffix" "$pkg" |
---|
27 | fi |
---|
28 | if hash zwrite 2>/dev/null; then |
---|
29 | zwrite -d -c debathena -i apt -m "Moved $pkg from $old_suffix to ${new_suffix:-production}" |
---|
30 | fi |
---|
31 | done |
---|
Note: See
TracBrowser
for help on using the repository browser.