summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/stex/bin/README
blob: 6af84e42bab454f0ae87c327d2c014860ca28fad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
msplit
"Module Split"

Usage: 
    msplit <input filename> [options]

Options:   
    --output <filename>	filename of new main .tex file; default stdout
    --path <path>	path where to write the module files;
    --header <filename> filename of header file to be included in all new .tex files
    --verbose     	verbose on
    --stop        	stop when \end{document} is found, not at EOF
    --help        	show help screen


NOTE: All options '--xoption' can be replaced by '-x' as long as there is only one option starting with 'x' 

This program splits the .tex file given at input into: 
	one main .tex file, that includes
	more .tex files, each containing one module

The name of the new main .tex file is specified by output option. The path to the inputted
files can be specified by path. The name of one generated input file is "name of the
module it contains".tex Running on one already split file will just make a copy.  Example
usage: ./msplit slides.tex -o sl.tex -p ./modules -s

Interpretation: "Split the file slides.tex; wite the new main file as sl.tex and the
inputted files should be placed in ./modules; if path does not exist, it is automatically
created; stop when (uncommented) \end{document} is found."



rf
"Reuse Factor"

Usage:
    rf [options]

Options:
    --input <filename>	.tex input file. stdin by default
    --stop		stop when \end{document} is found, not at EOF
    --verbose		verbose on
    --help		show help screen


This program computes the reuse factor for the .tex document given at input. This number
represents the ratio of latex processed lines of code to actual lines contained in file
given at input. This number will always be 1 for files that have no \input or \include.

Example usage:
./rf -v -i slides.tex
Interpretation: "Compute the reuse factor of slides.tex and show all processed files(verbose mode)."



sgraph
"Slides graph [representation]"

Usage:
    sgraph [options]

Options:
    --input <filename>		.tex input file; stdin by default
    --output <filename>		output file; out.dot by default
    --format <ps|png|jpg|...>	output format; .ps by default; for available formats, see dot --help
    --nodot			do not generate .dot file, just target format
    --root <string>		the 'root' of the graph. (name of course)
    --theory <string>		generate a subgraph for the theory
    --sliderange <begin:end>	only look at the given slide range; (2:16 for example)
    --stop			stop reading data when \end{document} is found, not at EOF
    --verbose			verbose on
    --help			show help screen

This program generates a .dot file readable by graphviz, containing a graph of the module
usage in the .tex file given at input, optionally looking at a specific theory and/or
slide range; it also adds a dummy 'root' for the graph, so one can see where everything
starts. It then converts the .dot file to a given format (.ps by default) using graphviz
and optionally deletes the intermediary .dot file.

Example usage:
./sgraph -i slides.tex -o graph -f ps -n -t TCN --sliderange 20:10000 -r GenCS -v

Interpretation: "Generate the graph of slides.tex in .ps format, write it in graph.ps, do
not keep the .dot file; include only the part needed for the theory 'TCN' and in the slide
range 20 to 10000; use as root for the graph the string 'GenCS' and show all processed
files."


sms
??

Usage:
    sms [options]

Options:
    --input <filename>	.tex file to split; default stdin
    --verbose     	verbose on
    --stop        	stop when \end{document} is found, not at EOF
    --help        	show help screen

Generate .sms file from .tex file given at input; .sms files contain only the modules and
the macros defined within, no other text.

Example usage:
./sms -i slides.tex -s

Interpretation: "Generate the slides.sms file for slides.tex; Stop when \end{document} is found."




bms
"Build Module Structure"

Usage:
    bms [options]

Options:
    --input <filename>    .tex file to read from
    --graph <filename>    if mentioned, produce the suggested module structure as
                          a graphviz digraph (.dot file)
    --path <pathname>     if mentioned, produce same input file/s (including
                          dependencies) in specified path with suggested
                          module structure.
    --output <filename>   the new name of the main .tex file in specified path
    --root <string>       if mentioned, a father module is included, so that all
                          other modules descend from it. generally the course name
    --stop                stop when \end{document} is found; default is to go on
    --definitions         show a list of all definitions
    --verbose             verbose on
    --help                show help screen


This program has the purpose of computing a default module structure, such that a module
uses another module if and only if it needs that module and does not need another
descendant of it. First, the prgram reads all necessary data from the input .tex file,
computes the minimal strictly required module usage structure, and writes it as a graphviz
digraph, and/or writes a copy of the input .tex file (and maybe inputted files by the .tex
file) with the new module structure in the given path. All paths are created if not
existing.

Example usage:
./bms -i slides.tex -s -g - | dot -Tps > out.ps; ggv out.ps
./bms -i slides.tex -g out.dot -p ./new

Interpretation: "Build default module structure for slides.tex and write it to out.dot;
also use the obtained module structure and copy the input file to given path with changed
module usage."

rng2dot
Convert Relax NG Compact form to Graphviz dot file