PageRenderTime 3ms CodeModel.GetById 1ms app.highlight 0ms RepoModel.GetById 1ms app.codeStats 0ms

/get-inputs.sed

https://code.google.com/p/latex-makefile/
sed | 23 lines | 12 code | 1 blank | 10 comment | 0 complexity | 6171f900f3d56978f3bebab774284ac0 MD5 | raw file
 1#(##defaults(target_files="TARGET_FILES")##)
 2
 3# only look at INPUT lines from the .fls file
 4/^INPUT/!d
 5# Remove references to the current directory, make all entries relative
 6s!^INPUT \(\./\)\{0,1\}!!
 7# Escape filepath spaces
 8s/[[:space:]]/\\ /g
 9# Depend on .tex, not on .aux
10s/\(.*\)\.aux$/\1.tex/
11# NOTE: BSD sed does not understand \|, so we have to do something more
12# clunky to extract suitable extensions.
13/\.tex$/b addtargets
14/\.cls$/b addtargets
15/\.sty$/b addtargets
16/\.pstex_t$/b addtargets
17/\.dot_t$/b addtargets
18d
19# Here we add the input targets.  This involves calling path-norm, which on
20# cygwin systems will change the path to not contain spaces and to be
21# unix-style instead of C:\Windows style.
22:addtargets
23s!.*!(##target_files##): $(call path-norm,&)!