Dolda2000 GitWeb
/
dcp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8bcd59d
)
Fix repo sharing.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 6 Jan 2008 02:08:23 +0000
(
03:08
+0100)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 6 Jan 2008 02:08:23 +0000
(
03:08
+0100)
dcp-init
patch
|
blob
|
blame
|
history
diff --git
a/dcp-init
b/dcp-init
index
6984bad
..
05e39fd
100755
(executable)
--- a/
dcp-init
+++ b/
dcp-init
@@
-3,7
+3,7
@@
set -e
usage() {
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...]"
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 " 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"
@@
-139,6
+139,7
@@
EOF
defdir=/srv/dcp
repodir=
confopts=()
defdir=/srv/dcp
repodir=
confopts=()
+shared=n
while [ "${1:0:1}" = - ]; do
opt="${1:1}"
while [ "${1:0:1}" = - ]; do
opt="${1:1}"
@@
-149,6
+150,8
@@
while [ "${1:0:1}" = - ]; do
elif [ "$opt" = h ]; then
usage
exit 0
elif [ "$opt" = h ]; then
usage
exit 0
+ elif [ "$opt" = s ]; then
+ shared=y
elif [ "$opt" = C ]; then
confopts=("${confopts[@]}" "$1")
shift
elif [ "$opt" = C ]; then
confopts=("${confopts[@]}" "$1")
shift
@@
-229,5
+232,9
@@
while [ $# -gt 0 ]; do
done
git clone -q --bare "$td" "$repodir"
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"
rm -rf "$td"