X-Git-Url: http://dolda2000.com/gitweb/?a=blobdiff_plain;f=dcp-init;h=262a2bbd86349c4f6e5f6e801951930cc0660187;hb=078110f603005fe613307254dfbc317f0d0b1b40;hp=7bd3d7e85a786c1e3b9961fdae4642979f8c5bd1;hpb=9f26b93f6e237e1abcd9ff6ee7937eed6799dd70;p=dcp.git diff --git a/dcp-init b/dcp-init index 7bd3d7e..262a2bb 100755 --- a/dcp-init +++ b/dcp-init @@ -3,10 +3,11 @@ set -e usage() { - echo "usage: dcp-init [-C key=val] [-d REPODIR] PACKAGE [PATCH...]" + echo "usage: dcp-init [-sh] [-C key=val] [-d REPODIR] PACKAGE [(PATCH|-m)...]" echo " PATCH ::= [-p LEVEL] [-bB BRANCH] FILE" echo " -b creates a new branch at the current patch" echo " -B creates a new branch at the upstream sources" + echo " -m merges the current branch into the master branch" } rungit() { @@ -20,9 +21,6 @@ getaptsrc() { mkdir "$td/apt-tmp" (cd "$td/apt-tmp"; apt-get source "$1") || false - echo Achtung - sleep 10 - sdir= for f in "$td/apt-tmp"/*; do if [ -d "$f" ]; then @@ -45,7 +43,7 @@ getaptsrc() { } initrepo() { - rungit init -q + rungit init mkdir "$td/control" touch "$td/control/conf" rungit add control @@ -58,6 +56,11 @@ initbase() { mkdir "$td/control/update.d" cat >"$td/control/functions" <&2 exit 1 @@ -232,5 +245,9 @@ while [ $# -gt 0 ]; do done git clone -q --bare "$td" "$repodir" +if [ "$shared" = y ]; then + chmod -R g+w "$repodir" + td="$repodir" rungit config core.sharedrepository 1 +fi rm -rf "$td"