Newbie questions: integrating ruby/perl scripts into a document; changing line spacing for typed text only
![](https://secure.gravatar.com/avatar/30ef4fea8acc9a4c7a392675260cfcb9.jpg?s=120&d=mm&r=g)
Hello, I want to ask a few questions that I cannot resolve by myself so far. 1) How can I integrate ruby/perl scripts into a .tex document? (I want to create a CD cataloguing tool and gonna use script for reading CD file list). 2) How to change line spacing for typed text only? (I use medium space for the whole document but want minimal spacing inside \starttyping)? With beat regards, Vyatcheslav Yatskovsky
![](https://secure.gravatar.com/avatar/386a116d129cdc597f2bb6210bbaff7a.jpg?s=120&d=mm&r=g)
On 2/15/07, Vyatcheslav Yatskovsky
Hello,
I want to ask a few questions that I cannot resolve by myself so far.
1) How can I integrate ruby/perl scripts into a .tex document? (I want to create a CD cataloguing tool and gonna use script for reading CD file list).
\executesystemcommand{some_external_program ...} luigi
![](https://secure.gravatar.com/avatar/145586de2f69e4b887749da370090dc3.jpg?s=120&d=mm&r=g)
On 2007-02-15, at 18:16.0, Vyatcheslav Yatskovsky wrote:
1) How can I integrate ruby/perl scripts into a .tex document? (I want to create a CD cataloguing tool and gonna use script for reading CD file list).
By coincidence I've just written something about this too. Not for ruby/perl, but there may be a few atoms of knowledge that add to your understanding: http://newlisper.blogspot.com/2007/02/newlisp-in-context.html (By the way - can I thank you personally, Hans, and the other helpful people on this list for your help - I completed my document and am pleased with the result...!)
![](https://secure.gravatar.com/avatar/c5ae4f9aa0d3a9bd5376e92b322c3e50.jpg?s=120&d=mm&r=g)
On Sat, 17 Feb 2007, cormullion@mac.com wrote:
On 2007-02-15, at 18:16.0, Vyatcheslav Yatskovsky wrote:
1) How can I integrate ruby/perl scripts into a .tex document? (I want to create a CD cataloguing tool and gonna use script for reading CD file list).
By coincidence I've just written something about this too. Not for ruby/perl, but there may be a few atoms of knowledge that add to your understanding:
http://newlisper.blogspot.com/2007/02/newlisp-in-context.html
Interesting. Just a couple of points. Do not use the prefix m- for your modules. m- is reserved for modules in the core distribution. You can use t- (third party) if you want to distribute your module, or p- (personal) if you do not want to distribute your module. Looking at the code, I do not think that you need \def\NL{NL}. Also \NL is an internal command used in tables. Finally, in the definition of \stopNLE, you can replace \input \NLfile.out with \typefile{\NLfile.out} in which case you will not need to escape all the special characters. ConTeXt will do it for you. Your manual looks good, and easy to read. I think I will give newlisp a try to try to understand what is the whole fuss about lisp anyway :) Aditya
![](https://secure.gravatar.com/avatar/145586de2f69e4b887749da370090dc3.jpg?s=120&d=mm&r=g)
On 2007-02-17, at 18:45.0, Aditya Mahajan wrote:
Interesting. Just a couple of points. Do not use the prefix m- for your modules. m- is reserved for modules in the core distribution. You can use t- (third party) if you want to distribute your module, or p- (personal) if you do not want to distribute your module.
Thanks - you can tell I took your advice to look at m-r.tex a bit too far! ;-)
Looking at the code, I do not think that you need \def\NL{NL}. Also \NL is an internal command used in tables.
Finally, in the definition of \stopNLE, you can replace \input \NLfile.out with \typefile{\NLfile.out} in which case you will not need to escape all the special characters. ConTeXt will do it for you.
OK. In fact I originally had two commands - one for verbatim-text, the other for generating material to be included in 'ordinary paragraphs'. I originally had the code examples output using the vim-module. It worked great! But I just couldn't find a colour scheme that made the code more readable - most of the things I tried just made it look garish and less readable. Perhaps coloured syntax listings are too personal a thing... (And yes, it did slow down the process a tiny bit :-))
Your manual looks good, and easy to read. I think I will give newlisp a try to try to understand what is the whole fuss about lisp anyway :)
Have fun! thanks again to you and everybody who helped...
participants (4)
-
Aditya Mahajan
-
cormullion@mac.com
-
luigi scarso
-
Vyatcheslav Yatskovsky