Girocco/Notify.pm: perform our own JSON body encoding
[girocco.git] / bin / run-format-readme.sh
blob8d31afe9b6af729f4053efdcc92ceb79c000bc48
1 #!/bin/sh
3 set -e
5 . @basedir@/shlib.sh
7 base="${1#$cfg_reporoot}"
8 base="${base#/}"
9 base="${base%/}"
10 fp="$base"
11 base="${cfg_gitweburl%/}/$base"
12 base="${base#*://}"
13 base="/${base#*/}"
14 img="${base%/}/blob_plain/HEAD:"
15 base="${base%/}/blob/HEAD:"
16 max="${cfg_max_readme_size}"
18 PATH="$var_git_exec_path:$cfg_basedir/bin:/usr/bin:$PATH"
19 export PATH
21 exec "$cfg_basedir/bin/format-readme" -e ${max:+-m} $max -b "$fp" -p "$base" -i "$img" "$@"