forked from annotation/text-fabric
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommitapps.sh
More file actions
executable file
·51 lines (45 loc) · 994 Bytes
/
Copy pathcommitapps.sh
File metadata and controls
executable file
·51 lines (45 loc) · 994 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/bin/sh
function givehelp {
echo "./commitapps.sh <app> <msg>"
echo ""
echo "Commit and push <app> with <tag>, <name>, <msg>"
echo "If <app> == 'all', then all apps will be committed and pushed"
echo ""
}
# Create a new release for all or some apps
annotationdir=~/github/annotation
tooldir=${annotationdir}/text-fabric/tools
tool="${tooldir}/release.py"
if [[ "$1" == "" ]]; then
givehelp
echo "Provide an app (or 'all') and a commit message"
exit
else
app="$1"
shift
fi
if [[ "$1" == "" ]]; then
givehelp
echo "Provide commit message"
exit
else
msg="$1"
shift
fi
cd $annotationdir
if [[ "$app" == "all" ]]; then
echo "All apps: commit changes and push"
apps=`ls -d app-*`
else
echo "${app}: commit changes" and push
apps=`ls -d app-$app`
fi
for app in $apps
do
echo "o-o-o [$app] o-o-o"
cd $annotationdir/$app
git add --all .
git commit -m "$msg"
git push origin master
done
echo "done"