Revision 24079,
946 bytes
checked in by broder, 15 years ago
(diff) |
Add convenience repo-management scripts dacopy and daremove, and
change damove to use those.
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | # Usage: dacopy NEW_SUFFIX OLD_SUFFIX SOURCE_PACKAGE |
---|
4 | |
---|
5 | # Copy 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 copies any source or binary package built from the source |
---|
9 | # package PACKAGE |
---|
10 | |
---|
11 | : ${DEBATHENA_APT=/mit/debathena/apt} |
---|
12 | . $(dirname "$0")/debian-versions.sh |
---|
13 | |
---|
14 | if [ "$#" -lt 3 ]; then |
---|
15 | echo "Usage: dacopy NEW_SUFFIX OLD_SUFFIX SOURCE_PACKAGE" >&2 |
---|
16 | exit 1 |
---|
17 | fi |
---|
18 | |
---|
19 | case "${1}/${2}" in |
---|
20 | /-proposed) ;; |
---|
21 | /-development) ;; |
---|
22 | -proposed/-development) ;; |
---|
23 | *) |
---|
24 | echo "WAIT. You are about to copy $3" |
---|
25 | echo " FROM debathena$2 TO debathena$1," |
---|
26 | echo -n "which is probably backwards. Is that a good idea [yes/N]? " |
---|
27 | read yn |
---|
28 | if [ "$yn" != "yes" ]; then |
---|
29 | echo "that's what I thought. Exiting." |
---|
30 | exit 1 |
---|
31 | fi ;; |
---|
32 | esac |
---|
33 | |
---|
34 | for code in $DEBIAN_CODES; do |
---|
35 | reprepro -Vb $DEBATHENA_APT copysrc "${code}${1}" "${code}${2}" "$3" |
---|
36 | done |
---|
Note: See
TracBrowser
for help on using the repository browser.