Hello, Is it possible to move the .so command to a macro. For instance let's say I have a macro
.de source .so \\$1 .. and call it like so: .source complex1.roff. It seems like the soelim is getting the .so in the source macro. If I put the macro in the main complex.roff file it says that it can not find the source file \\$1. But if I create a tmac and use that with groff (groff -M. -mfoo -eps complex.roff > complex.ps) It does not complain, but does not process the equations and the pictures in the files. I could as well just write a preprocessor, to process all the files, and generate a huge document and run that through the groff processor. But did not want to do that, and wanted to know if that is possible with groff. Riza On Tue, Nov 14, 2023 at 7:18 AM G. Branden Robinson < g.branden.robin...@gmail.com> wrote: > Hi Riza, > > At 2023-11-14T06:59:54+0300, Riza Dindir wrote: > > I am having trouble again with macros, soelim. > > > > I am writing a document that will have pic's and equation's in it. I > > wanted to separate these into files. One file for each chapter. > > That sounds reasonable. > > > But I am having trouble doing this. > > Here's an example that works for me. > > $ cat complex.roff > This is my complex roff document. > .sp > .so complex1.roff > .so complex2.roff > .sp > This concludes my document. > $ cat complex1.roff > .sp > \fBChapter One\fP > .sp > .EQ > a + b + c = 1 > .EN > .sp > .PS > circle; > .PE > $ cat complex2.roff > .sp > \fBChapter Two\fP > .sp > .EQ > d + e + f = 2 > .EN > .sp > .PS > box; > .PE > $ groff -eps ./complex.roff >| complex.ps > $ okular complex.ps > > And I see everything I expect. > > Can you reproduce this behavior? > > Regards, > Branden >