SHELLCAT(1)

πŸ“¦ version 1.2, in alpine 3.24

πŸ’– SHELLCAT(1) πŸ’–

okay so bestie, welcome to the manual page for shellcat, section 1 β€” the templating system with shell syntax. It’s literally the main character of this page, and we’re gonna get you comfy with it. 🫢

✨ SYNOPSIS ✨

shellcat [-s SHELL] TEMPLATE [ARG...]

shellcat {-h | --help | -v | --version}

🌈 DESCRIPTION 🌈

shellcat is a template processor, which uses shell script syntax. It can be used to produce static HTML pages, or pre-process any sort of text document. Slay. πŸ’…

πŸŽ€ OPTIONS πŸŽ€

  • -s, --shell=SHELL β€” Use the specified shell. The default is /bin/sh. 🐚
  • -h, --help β€” Display help and exit. Byeee πŸ‘‹
  • -v, --version β€” Output version information and exit. πŸ’«

πŸ¦‹ TEMPLATE SYNTAX πŸ¦‹

  • text β€” Unless specified otherwise below, any text is echoed verbatim:
$ cat ex1.sc
Hello world!

$ shellcat ex1.sc
Hello world!
  • #!interpreter β€” If the first line of the template starts with #! characters, it is completely ignored. This allows for executable scripts with shellcat as interpreter:
$ cat ex2.sc
#!/usr/bin/shellcat
Hello world!

$ chmod +x ex2.sc
$ ./ex2.sc
Hello world!
  • <$ code $> β€” The code is executed by the shell:
$ cat ex3.sc
<$ for x in $(seq 3); do $>Hello world!
<$ done $>

$ shellcat ex3.sc
Hello world!
Hello world!
Hello world!
Whitespace around code is strongly recommended, but not obligatory; see below however. ⚠️
  • -$> β€” If used inside a code block, the $> sequence (with the leading minus sign omitted) is used in the shell code:
$ cat ex4.sc
<$ echo '-$> not closed yet' $>

$ shellcat ex4.sc
$> not closed yet
  • <$- β€” If used outside a code block, the <$ sequence (with the trailing minus sign omitted) is output:
$ cat ex5.sc
<$- not code $>

$ shellcat ex5.sc
<$ not code $>

🌸 ENVIRONMENT 🌸

The following environment variables are available for the processes spawned by shellcat:

  • SHELLCAT β€” name of the shellcat interpreter. πŸ‘‘

Variables which existed in the environment are not modified, but left intact. No cap. πŸ’―

πŸ’œ SEE ALSO πŸ’œ

sh(1) β€” go give your shell bestie some love too. πŸšπŸ’–


mwah πŸ’‹ this little page is for shellcat version 1.2, dated 2022-10-24 β€” catch you in the next manpage, bestie! πŸŽ€βœ¨πŸ«Ά

πŸ“¦ where this page comes from