Today is: Thursday April 18, 2024
How to use Perl in your LaTeX Design Flow?
Anyone who typesets with LaTeX has probably grown tired of creating new LaTeX
top level or lower level modules. I have generated a couple of Perl Scripts
that will automatically generate the top level module and lower level module
for you. These Perl Scripts can be invoked from within a Cygwin or a DOS Command Window.
Below are the scripts:
- latex_new.pl : LaTeX Top Level Document Template Perl Script [download]
- latex_bot.pl : LaTeX Lower Level Document Template Perl Script [download]
How to use latex_new.pl?
This utility is intended to make creating new LaTeX modules easier. This script
will create a new LaTeX file called "new_module_name.tex" when you type the
following command:
!! latex_new.pl new_module_name.tex
The script will generate the empty LaTeX template for you in the file
"new_module_name.tex". Note: "new_module_name.tex" is the name of the new LaTeX
file and can be anything you like. You can either use Cygwin or a DOS
Command prompt to run this script. If you want to use
a Cygwin or a DOS Command prompt, then see the instructions below:
- Change directory to the desired directory
- cd C:\design\new_module
- If the directory "new_module" does not exist type: mkdir C:\design\new_module, before changing directory.
- Type the following: perl latex_new.pl new_module_name.tex
- When the script is finished you will see the message: "The script has finished successfully! You can now use new_module_name.tex."
How to use latex_bot.pl?
This utility is intended to make creating new LaTeX modules easier. This script
will create a new LaTeX file called "new_module_name.tex" when you type the
following command:
!! latex_bot.pl new_module_name.tex
The script will generate the empty LaTeX template for you in the file
"new_module_name.tex". Note: "new_module_name.tex" is the name of the new LaTeX
file and can be anything you like. You can either use Cygwin or a DOS
Command prompt to run this script. If you want to use
a Cygwin or a DOS Command prompt, then see the instructions below:
- Change directory to the desired directory
- cd C:\design\new_module
- If the directory "new_module" does not exist type: mkdir C:\design\new_module, before changing directory.
- Type the following: perl latex_new.pl new_module_name.tex
- When the script is finished you will see the message: "The script has finished successfully! You can now use new_module_name.tex."
Jeremy W. Webb
Last Modified: Wednesday, March 18, 2015 09:45:35 AM