Revision 25747,
623 bytes
checked in by jdreed, 12 years ago
(diff) |
Get rid of "dirname $0" and replace with DA_SCRIPTS_DIR, which
allows overriding at run time. (Trac: #1191)
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | # |
---|
3 | # Gives you an interactive shell with Debathena repositories configured |
---|
4 | |
---|
5 | if [ -z "$1" ] || [ -z "$2" ]; then |
---|
6 | echo "usage: daschroot <dist> <arch>" |
---|
7 | exit 1 |
---|
8 | fi |
---|
9 | dist="$1" |
---|
10 | arch="$2" |
---|
11 | shift 2 |
---|
12 | |
---|
13 | : ${DA_SCRIPTS_DIR="$(dirname "$0")"} |
---|
14 | |
---|
15 | if ! schroot -c "$dist-$arch-sbuild" -i >/dev/null; then |
---|
16 | exit $? |
---|
17 | fi |
---|
18 | |
---|
19 | session=$(schroot -c "$dist-$arch-sbuild" -b) |
---|
20 | schroot -c "$session" -r -u root -- env SBUILD_BUILD_CONF_DISTRIBUTION="$dist" "$(readlink -f "$DA_SCRIPTS_DIR/chroot-sources")" |
---|
21 | if [ "$#" -gt 0 ]; then |
---|
22 | echo "I: Entering schroot session $session" |
---|
23 | fi |
---|
24 | schroot -c "$session" -r "$@" |
---|
25 | schroot -c "$session" -e |
---|
Note: See
TracBrowser
for help on using the repository browser.