blob: cb7f1a66c24c1992967cbb68a3202c5e23a70584 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
#!/bin/sh
set -eu
readonly GiteaURL='https://code.causal.agency/june/src/src/branch/master/bin'
src=$1
man=${2:-}
./hi -f html -o document,tab=4 -n "${src}" /dev/null | sed '/<pre/d'
cat <<- EOF
<code><a href="${GiteaURL}/${src}">${src} in git</a></code>
EOF
[ -f "${man}" ] && man -P cat "${PWD}/${man}" | ./ttpre
./hi -f html -o anchor "${src}"
|