From: Martin Pitt Date: Sat, 6 Dec 2014 12:30:33 +0000 (+0100) Subject: add schrootbd X-Git-Url: https://piware.de/gitweb/?a=commitdiff_plain;h=eb40df7f71e3f8c5004898b949797c162344ab68;p=bin.git add schrootbd --- diff --git a/schrootbd b/schrootbd new file mode 100755 index 0000000..2e0d400 --- /dev/null +++ b/schrootbd @@ -0,0 +1,14 @@ +#!/bin/sh +set -e +schroot="$1" +pkg="$2" + +if [ -z "$pkg" ]; then + echo "Usage: $0 " >&2 + exit 1 +fi + +SESSID=$(schroot -b -c "$schroot" -n "schroot-$schroot-$pkg") +schroot -r -c session:$SESSID -u root -- apt-get -y build-dep "$pkg" +echo "You will now be put into the schroot. It will NOT be cleaned up when you exit this shell!" +schroot -r -c session:$SESSID