diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2023-05-07 22:17:35 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2023-05-07 22:17:35 +0200 |
| commit | fbea748c39fdc346612e7b4f18d3518f55cc8424 (patch) | |
| tree | 89554aaf9223a587adc4ed7e3303417c6c81dcca | |
| parent | 6ed532078680a6735811aa40a3b41c2a77c0da42 (diff) | |
| download | git-hooks-fbea748c39fdc346612e7b4f18d3518f55cc8424.tar.gz git-hooks-fbea748c39fdc346612e7b4f18d3518f55cc8424.zip | |
Fixes
| -rw-r--r-- | Makefile | 3 | ||||
| -rwxr-xr-x | copy-hook | 6 | ||||
| -rwxr-xr-x | post-receive-stagit | 6 |
3 files changed, 12 insertions, 3 deletions
| @@ -3,8 +3,9 @@ all: push | |||
| 3 | 3 | ||
| 4 | push: | 4 | push: |
| 5 | ssh git@tronto.net mkdir -p BIN FILES | 5 | ssh git@tronto.net mkdir -p BIN FILES |
| 6 | scp post-receive-stagit git@tronto.net:BIN/ | 6 | scp post-receive-stagit copy-hook git@tronto.net:BIN/ |
| 7 | scp bottom.html favicon.png logo.png style.css git@tronto.net:FILES/ | 7 | scp bottom.html favicon.png logo.png style.css git@tronto.net:FILES/ |
| 8 | ssh git@tronto.net /home/git/BIN/copy-hook | ||
| 8 | 9 | ||
| 9 | index: push | 10 | index: push |
| 10 | ssh git@tronto.net /home/git/BIN/post-receive-stagit index | 11 | ssh git@tronto.net /home/git/BIN/post-receive-stagit index |
diff --git a/copy-hook b/copy-hook new file mode 100755 index 0000000..a88a58d --- /dev/null +++ b/copy-hook | |||
| @@ -0,0 +1,6 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | for d in *.git; do | ||
| 4 | cp BIN/post-receive-stagit $d/hooks/ | ||
| 5 | chmod +x $d/hooks/post-receive-stagit | ||
| 6 | done | ||
diff --git a/post-receive-stagit b/post-receive-stagit index 586a533..57b5732 100755 --- a/post-receive-stagit +++ b/post-receive-stagit | |||
| @@ -80,6 +80,7 @@ mkpage() { | |||
| 80 | adddownloadbutton $f | 80 | adddownloadbutton $f |
| 81 | addbottombar $f | 81 | addbottombar $f |
| 82 | done | 82 | done |
| 83 | mkindex | ||
| 83 | } | 84 | } |
| 84 | 85 | ||
| 85 | mkindex() { | 86 | mkindex() { |
| @@ -98,7 +99,8 @@ if [ "$1" = "all" ]; then | |||
| 98 | $bindir/post-receive-stagit | 99 | $bindir/post-receive-stagit |
| 99 | cd | 100 | cd |
| 100 | done | 101 | done |
| 101 | elif [ "$1" != "index" ]; then | 102 | elif [ "$1" = "index" ]; then |
| 103 | mkindex | ||
| 104 | else | ||
| 102 | mkpage | 105 | mkpage |
| 103 | fi | 106 | fi |
| 104 | mkindex | ||
