Skip to content

Commit

Permalink
Merge pull request #1356 from henryso/lua-fix-kakuto
Browse files Browse the repository at this point in the history
Lua-based fixes from Akira Kakuto.
  • Loading branch information
henryso authored Apr 16, 2017
2 parents 569a0f0 + afc20dc commit f2dd4c5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tex/gregoriotex.lua
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,9 @@ local function gregorio_exe()
-- first look for one with the exact version
real_gregorio_exe = 'gregorio-5_0_0' -- FILENAME_VERSION
exe_version = io.popen(real_gregorio_exe..' --version', 'r')
exe_version = exe_version:read("*line")
if exe_version then
exe_version = exe_version:read("*line")
end
if not exe_version then
-- look for suffix-less executable
real_gregorio_exe = 'gregorio'
Expand Down Expand Up @@ -771,7 +773,7 @@ local function compile_gabc(gabc_file, gtex_file, glog_file, allow_deprecated)
extra_args = extra_args..' -D'
end

local cmd = string.format("%s %s -W -o %s -l %s '%s'", gregorio_exe(),
local cmd = string.format('%s %s -W -o %s -l %s "%s"', gregorio_exe(),
extra_args, gtex_file, glog_file, gabc_file)
res = os.execute(cmd)
if res == nil then
Expand Down

0 comments on commit f2dd4c5

Please sign in to comment.