about summary refs log tree commit diff
path: root/pkgs/misc/tex/nix/lhs2tex.sh
blob: 6edca4baf8a027a7b31e26b6818f749cb52034b3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
source $stdenv/setup

ensureDir $out

mkdir root
cd root

startDir=$(perl $copyIncludes $includes)
cd $startDir

lhstex() {
    sourceFile=$1
    targetName=$out/$(basename $(stripHash $sourceFile; echo $strippedName) .lhs).tex
    echo "converting $sourceFile to $targetName..."
    lhs2TeX -o "$targetName" $flags "$sourceFile"
}

lhstex $source