projects
/
git-tools-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f477a7c
)
check for valid types pub/private
author
Wolfram Schneider
<wosch@indexdata.dk>
Fri, 10 Jan 2014 13:27:25 +0000
(13:27 +0000)
committer
Wolfram Schneider
<wosch@indexdata.dk>
Fri, 10 Jan 2014 13:27:25 +0000
(13:27 +0000)
id-new-project/id-new-project.sh
patch
|
blob
|
history
diff --git
a/id-new-project/id-new-project.sh
b/id-new-project/id-new-project.sh
index
f2690b2
..
89d190b
100755
(executable)
--- a/
id-new-project/id-new-project.sh
+++ b/
id-new-project/id-new-project.sh
@@
-1,6
+1,7
@@
#!/bin/sh
usage() {
+ echo ""
echo "Usage:"
echo "id-new-project.sh srcdir description {pub/private}"
echo "For example:"
@@
-12,9
+13,10
@@
SRC=$1
DESC=$2
TYPE=$3
-if test -z "${TYPE}"; then
- usage
-fi
+case "${TYPE}" in
+ pub | private) ;;
+ * ) echo "invalid type: '$TYPE', use pub or private"; usage ;;
+esac
if test ! -e post-receive; then
echo "file post-receive must be in the current directory"