aboutsummaryrefslogtreecommitdiff
path: root/docs/default.do
blob: 2742edb793322dd63007d67972e5f48ee20df1fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
. ../config.rc

# Extensionless name of file
fn="${1%.*}"

case "$1" in
    all)  redo-ifchange info ;;
    info) redo-ifchange cpt.info ;;
    *.info)
        redo-ifchange "$fn.texi"
        $MAKEINFO "$fn.texi" -o "$3"
        ;;
    *.texi)
        [ -f "$fn.org" ] || exit 99
        redo-ifchange "$fn.org"
        $EMACS "$fn.org" --batch -f org-texinfo-export-to-texinfo
        mv "$1" "$3"
        ;;
    *)
        echo "Unknown target $1"
        exit 99
esac

PHONY all info html