diff options
author | Karl Berry <karl@freefriends.org> | 2015-02-28 22:49:36 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-02-28 22:49:36 +0000 |
commit | ae750b9d9f9b660a211c98ee92e45a5ec9f42dea (patch) | |
tree | 21a2f38bae7bb139c78e4634c9fd7562cef14a0e /Master/texmf-dist/scripts/musixtex | |
parent | 3b4f0a07480eef603c2582c56ceef707e9849ce6 (diff) |
musixtex (28feb15)
git-svn-id: svn://tug.org/texlive/trunk@36401 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/musixtex')
-rwxr-xr-x | Master/texmf-dist/scripts/musixtex/musixtex.lua | 32 |
1 files changed, 27 insertions, 5 deletions
diff --git a/Master/texmf-dist/scripts/musixtex/musixtex.lua b/Master/texmf-dist/scripts/musixtex/musixtex.lua index 92cb3c3623e..3d7b2a08f74 100755 --- a/Master/texmf-dist/scripts/musixtex/musixtex.lua +++ b/Master/texmf-dist/scripts/musixtex/musixtex.lua @@ -1,11 +1,11 @@ #!/usr/bin/env texlua -VERSION = "0.7" +VERSION = "0.9" --[[ musixtex.lua: processes MusiXTeX files (and deletes intermediate files) - (c) Copyright 2012 Bob Tennent rdt@cs.queensu.ca + (c) Copyright 2012-14 Bob Tennent rdt@cs.queensu.ca This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the @@ -26,6 +26,13 @@ VERSION = "0.7" --[[ ChangeLog: + version 0.9 2015-02-13 RDT + Add an additional latex pass to resolve cross-references. + Add -e0 option to dvips as given in musixdoc.tex + Add -x option to call makeindex + + version 0.8 2014-05-18 RDT + Add -g option version 0.7 2013-12-11 RDT Add -F fmt option @@ -58,9 +65,11 @@ function usage() print(" -p pdfetex (or pdflatex)") print(" -d dvipdfm") print(" -s stop at dvi") + print(" -g stop at ps") print(" -i retain intermediate files") print(" -1 one-pass [pdf][la]tex processing") print(" -F fmt use fmt as the TeX processor") + print(" -x run makeindex") print(" -f restore default processing") end @@ -77,10 +86,12 @@ end -- defaults: tex = "etex" musixflx = "musixflx" -dvi = "dvips" +dvips = "dvips -e0 " +dvi = dvips ps2pdf = "ps2pdf" intermediate = 1 passes = 2 +index = 0 exit_code = 0 narg = 1 @@ -113,7 +124,11 @@ repeat elseif this_arg == "-1" then passes = 1 elseif this_arg == "-f" then - tex = "etex"; dvi = "dvips"; ps2pdf = "ps2pdf"; intermediate = 1; passes = 2 + tex = "etex"; dvi = dvips; ps2pdf = "ps2pdf"; intermediate = 1; passes = 2; index = 0 + elseif this_arg == "-g" then + dvi = dvips; ps2pdf = "" + elseif this_arg == "-x" then + index = 1 elseif this_arg == "-F" then narg = narg+1 tex = arg[narg] @@ -130,7 +145,14 @@ repeat if (passes == 1 or os.execute(tex .. " " .. filename) == 0) and (passes == 1 or os.execute(musixflx .. " " .. filename) == 0) and (os.execute(tex .. " " .. filename) == 0) and - ((tex ~= "latex" and tex ~= "pdflatex") + ((tex ~= "latex" and tex ~="pdflatex") + or (index == 0) + or (os.execute("makeindex -q " .. filename) == 0)) and + ((tex ~= "latex" and tex ~= "pdflatex") + or (os.execute(tex .. " " .. filename) == 0)) and + ((tex ~= "latex" and tex ~= "pdflatex") + or (os.execute(tex .. " " .. filename) == 0)) and + ((tex ~= "latex" and tex ~= "pdflatex") or (os.execute(tex .. " " .. filename) == 0)) and (dvi == "" or (os.execute(dvi .. " " .. filename) == 0)) and (ps2pdf == "" or (os.execute(ps2pdf .. " " .. filename .. ".ps") == 0) ) |