diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0f88e79..3c697e5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,6 +51,7 @@ jobs: run: | mv ubanner ubanner.bak export LC_ALL=C.UTF-8 + export MANPATH="$HOME/.local/share/man" make test-installed verbose=1 mv ubanner.bak ubanner diff --git a/t/version.t b/t/version.t index 8dbfbb4..15441a6 100755 --- a/t/version.t +++ b/t/version.t @@ -34,8 +34,15 @@ then else echo 'ok 3' fi -line=$(grep '^[.]TH ' "$dir/doc/"*.1) -IFS=' "' read -r _ _ _ _ _ man_version _ <<< "$line" +if [[ $prog = ubanner ]] +then + man_target=$prog +else + man_target="$dir/doc/ubanner.1" +fi +echo "# man page target = $man_target" +line=$(MANWIDTH=80 man "$man_target" | tail -n 1) +IFS=' "' read -r _ man_version _ <<< "$line" echo "# man page version = $man_version" if [[ $man_version = $changelog_version ]] then