1

I am trying to use GregorioTex in texworks to write Gregorian chant, but every time I try to compile my tex file, the following error is thrown:

(...l/Programs/MiKTeX/tex/luatex/gregoriotex/gregoriotex.lua:159: attempt t o index a nil value (local 'tmp_gabcfile') stack traceback: ...l/Programs/MiKTeX/tex/luatex/gregoriotex/gregoriotex.lua:159: in upvalue 'g regorio_exe' ...l/Programs/MiKTeX/tex/luatex/gregoriotex/gregoriotex.lua:1117: in upvalue ' compile_gabc' ...l/Programs/MiKTeX/tex/luatex/gregoriotex/gregoriotex.lua:1290: in field 'in clude_score' [\directlua]:1: in main chunk. \gre@gregorioscore ...allowdeprecated@asboolean )} \or \gre@debugmsg {compile...

l.19 \gregorioscore{kyrie-17}

?

My tex file is written below:

% !TEX program = LuaLaTeX+se \documentclass[12pt]{article} \usepackage[margin=1in]{geometry} \usepackage{fullpage} \usepackage[autocompile]{gregoriotex} \grechangestyle{commentary}{\small\bfseries} \gresetmodenumbersystem{roman-majuscule} \begin{document} \begin{center} \Huge{Kyrie XVII} \end{center} \gresetheadercapture{date}{grecommentary}{} \gregorioscore{kyrie-17} \end{document} 

kyrie-17.gabc is a text file (saved as a .gabc) copied from the Gregorio Tutorial as follows:

name:Kyrie XVII; mode: 6; date: XIV\textsuperscript{o} s.; %% (c4)KY(f)ri(gfg)e(h.) *() e(ixjvIH'GhvF'E)lé(ghg')i(g)son.(f.) <i>bis</i>(::) Chri(ixj)ste(jv.hijv.) e(ixjvIH'GhvF'E)lé(ghg')i(g)son.(f.) <i>bis</i>(::) Ký(f)ri(hj)e(ixjjkij.) (z) e(ixjvIH'GhvF'E)lé(ghg')i(g)son.(f.) (::) Ký(f)ri(hj)e(ixjjkij.) *(,) (ixf!hjjkij.) **(,) (z) e(ixjvIH'GhvF'E)lé(ghg')i(g)son.(f.) (::) 

Update: After the exchange of comments between me and C. Peters, C. Peters suggested I tag MiKTeX in case the issue is higher up the system than just in TeXworks. My .gabc file is in the same folder as the .tex file, but it seems that when I try to compile the tex file, no .gaux file is produced nor is a tmp-gre folder with a .glog and .gtex file produced. I'm uncertain why these aren't automatically being produced, but I suspect that this has something to do with the issue. I updated everything I could after checking for updates on the MiKTeX Console. Thank you to anyone who helps out with this.

5
  • After having checked the extension (I deleted my "answer") a second question: Have you saved the .gabc file in the same directory as the tex-file? Commented Mar 12 at 13:49
  • Yeah I have the file saved in the same folder as my .tex file. Commented Mar 12 at 16:44
  • I just searched on "attempt t o index a nil value". One suggestion is that the TeX-installation needs an update. Otherwise maybe this link helps you: tex.stackexchange.com/questions/571268/… Commented Mar 12 at 18:59
  • I saw that too, so I opened the MiKTeX Console, checked for updates, updated all, and still no solution. I'll check out that link, thanks. Commented Mar 12 at 21:42
  • My last suggestion is: if you have the problem really with the files you published (and not only with your original file), then add to your question what you verified according to our comments and add a MiKTeX tag to your question. In TeXShop I don't have the problem, so it must be caused higher in the system. Commented Mar 13 at 7:27

1 Answer 1

3

As it turns out, the solution to my problem was to simply remove white space in the name of the .tex file. The file was named "Kyrie Test.tex" and simply changing the name to "Kyrie-Test.tex" allowed the file to compile and construct the missing .gaux, .glog, and .gtex files. Thus, in order to compile a tex file using GregorioTeX, the name of the tex file must be free of white space or else it won't compile.

1
  • Well done! In general: avoid spaces in music code and names (Terminal doesn't like them either, but you didn't tell the name of your tex file :-)). Gregorio works a little different from MusiXTeX, but try to get used to end lines with %. In MusiXTeX any unwanted space will lead to unwanted output. Commented Mar 15 at 7:22

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.