When writing a UNIX manual page, I realized that some phrase occurs multiple times. I'd like to define it once and reuse it (not by copying with the editor). I see that I can use variables (.ds) for multi-line text, but it fails when the phrase includes dot commands (like .B foo). Is there a solution (other than include files and the C preprocessor) for this?
How can I reuse a text portion with commands in nroff?
130 Views Asked by U. Windl At
1
There are 1 best solutions below
Related Questions in GROFF
- How to make a loop to compile groff documents into a specific folder
- Defining the header in groff mm does not change it in the first page
- Placing a PIC image in an arbitrary position of the page using ms macros
- Setting top margin in groff to zero using mm macros
- How do I assign a value in a macro from macro parameter in groff?
- My man page output does not start at first line of display
- Using groff to generate pdf man pages for a c program file
- Groff: how to successfully compile a manpage, containing Cyrillic in UTF-8?
- GROFF PDFPIC converted w ImageMagick to .ms document causes "troff: sample.ms:18: division by zero" and leads images to show very right of the pdf doc
- Extraneous space between characters/glyphs in groff eqn
- Run multiple commands with entr
- Aligning equations with multiple marks and lineups in `groff eqn`
- How to set all arguments of the Title line in manpage written in reStructuredText, converted to groff with pandoc
- Groff mom change table background color
- using groff inside of a flatpak container
Related Questions in TROFF
- Defining the header in groff mm does not change it in the first page
- Placing a PIC image in an arbitrary position of the page using ms macros
- Setting top margin in groff to zero using mm macros
- How do I assign a value in a macro from macro parameter in groff?
- Groff: how to successfully compile a manpage, containing Cyrillic in UTF-8?
- Convert troff to nroff
- GROFF PDFPIC converted w ImageMagick to .ms document causes "troff: sample.ms:18: division by zero" and leads images to show very right of the pdf doc
- groff putting single word on line after trap
- Period in a man page?
- mdoc(7) markup for accumulating options with arguments
- How can I reuse a text portion with commands in nroff?
- GNU make: several targets in one pattern rule
- man 7 groff_man - No manual entry for groff
- Is there a way to exit double column mode without page break in groff?
- extraneous space around italics and bolds in manpage?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
You could make your multi-line text into a macro. The downside is that to insert it you must invoke the macro rather than interpolating the string.
If you just need bolding inside your strings, you can include font changes: