[Pkg-ocaml-maint-commits] [SCM] dh-ocaml packaging branch, master, updated. debian/0.4.1-28-g4c46b9e
Stephane Glondu
steph at glondu.net
Thu Jun 18 17:25:53 UTC 2009
The following commit has been merged in the master branch:
commit 4c46b9e0b0ffd8f431903fcea13dab2a0bbaad64
Author: Stephane Glondu <steph at glondu.net>
Date: Thu Jun 18 19:09:32 2009 +0200
Remove bashisms and improve dom-mrconfig
diff --git a/tools/dom-mrconfig b/tools/dom-mrconfig
index 46f1f4d..d905878 100755
--- a/tools/dom-mrconfig
+++ b/tools/dom-mrconfig
@@ -1,11 +1,11 @@
-#!/bin/bash
+#!/bin/sh
set -e
-function msg() {
+msg() {
echo "I: $1"
}
-function output() {
+output() {
echo "$1" >> $OUTPUT
}
@@ -44,35 +44,35 @@ if [ -f $OUTPUT ]; then
fi
# Setting up mr lib
-output "[DEFAULT]
+output '[DEFAULT]
lib=
msg () {
- echo \"I: \$1\"
+ echo "I: $1"
}
git_checkout () {
- git clone git+ssh://git.debian.org$GIT_REPODIR\$1.git &&
- cd \$1 &&
+ git clone git+ssh://git.debian.org'"$GIT_REPODIR"'$1.git &&
+ cd $1 &&
{ git branch --track upstream remotes/origin/upstream || true; } &&
{ git branch --track pristine-tar remotes/origin/pristine-tar || true; }
}
svn_checkout () {
- svn co $SVN_REPODIR/\$1
+ svn co '"$SVN_REPODIR"'/$1
}
update_check () {
if [ -d .git ]; then
dom-safe-pull
else
svn update
- if [ -f \"trunk/README\" ] && [[ \"\`cat trunk/README\`\" =~ \"This package has moved\" ]]; then
+ if [ -f "trunk/README" ] && grep -q "This package has moved" trunk/README; then
cd ..
- msg \"Deleting old svn repository: packages/\$1\"
- rm -rf \$1
- msg \"Checkout new git repository\"
- git_checkout \$1
+ msg "Deleting old svn repository: packages/$1"
+ rm -rf $1/* $1/.*
+ msg "Checkout new git repository"
+ git_checkout $1
fi
fi
}
-"
+'
# Sections for Git repositories
for i in $GIT_PKGS; do
--
dh-ocaml packaging
More information about the Pkg-ocaml-maint-commits
mailing list