slweb

Једноставни генератор статичких веб страна
Дневник | Датотеке | Референце | ПРОЧИТАЈМЕ | ЛИЦЕНЦА

чување f84e37a8265240fa802e3638a4b5ad79494f1ef4
родитељ 296da2c665d10975d2fe58ca01e4fbdce2246cfa
Аутор: Страхиња Радић <contact@strahinja.org>
Датум:   Sat, 11 Sep 2021 10:08:22 +0200

Simplified the installation instructions

Signed-off-by: Страхиња Радић <contact@strahinja.org>

Diffstat:
AINSTALL | 34++++++++++++++++++++++++++++++++++
MREADME | 24+-----------------------
Mall.do | 2+-
Mindex.slw | 24+++++++++++++++---------
Minstall.do | 5+++--
Muninstall.do | 6++++--
измењених датотека: 6, додавања: 58(+), брисања: 37(-)

diff --git a/INSTALL b/INSTALL @@ -0,0 +1,34 @@ +Prerequisites +============= + +* C compiler (GCC-compatible) - ${SLWEB_CC:-gcc -g} +* gzip + + +Optional dependencies +--------------------- + +* KaTeX[1] for math mode +* git (for {git-log}) +* identify from ImageMagick[2] (for <img width="" height="">) + +[1]: https://katex.org +[2]: https://imagemagick.org + + +Install +------- + + $ git clone https://git.sr.ht/~strahinja/slweb + $ cd slweb + $ su + +If you have djb redo: + + # redo install + +if you don't: + + # ./do install + + diff --git a/README b/README @@ -6,32 +6,10 @@ slweb is a static website generator which aims at being simplistic. It transforms custom Markdown-like syntax into HTML. - Prerequisites - ------------- - -Aside from the obvious (a C compiler, by default GNU C), slweb requires groff(1) -and gzip(1) to create and compress documentation. git(1) is, aside from cloning -the repository, required to use the directive {git-log}. KaTeX[1] is optionally -used for math mode. ImageMagick's[2] program identify(1) is optionally used to -determine image sizes and output them as attributes to the <img> tag. - -[1]: https://katex.org -[2]: https://imagemagick.org - Install ------- -$ git clone https://git.sr.ht/~strahinja/slweb -$ cd slweb -$ su - - Then, if you have djb redo: - -# redo install - - if you don't: - -# ./do install +See the file INSTALL in this repository. Examples diff --git a/all.do b/all.do @@ -1,3 +1,3 @@ redo-ifchange slweb -redo-ifchange slweb.1.gz slweb.pdf index.html examples/all +redo-ifchange slweb.1.gz index.html examples/all diff --git a/index.slw b/index.slw @@ -14,14 +14,18 @@ meta: index-meta.csv **Slweb** is a static website generator which aims at being simplistic. It transforms custom Markdown-like syntax into HTML. + ## Prerequisites -Aside from the obvious (a C compiler, by default **GNU C**), slweb requires -**groff**(1) and **gzip**(1) to create and compress documentation. **git**(1) -is, aside from cloning the repository, required to use the directive -`{git-log}`. $\KaTeX$ ([https://katex.org][katex]) is optionally used for math -mode. [ImageMagick's][imgmg] program **identify**(1) is optionally used to -determine image sizes and output them as attributes to the `<img>` tag. +* C compiler (**GCC**-compatible) - `${SLWEB_CC:-gcc -g}` +* **gzip** + + +## Optional dependencies + +* [KaTeX][katex] for math mode +* **git** (for `{git-log}`) +* **identify** from [ImageMagick][imgmg] (for `<img width="" height="">`) ## Install @@ -44,9 +48,9 @@ if you don't: # ./do install ``` -You can specify any compiler which uses `-Wall`, `-c`, `-g` and `-o` like GNU C, -most notably **tcc**(1), by setting the `SLWEB_CC` environment variable. For -example: +You can specify any compiler which uses (or tolerates) `-Wall`, `-std=c99`, +`-c`, `-g` and `-o` like GNU C, most notably **tcc**(1), by setting the +`SLWEB_CC` environment variable. For example: ``` $ SLWEB_CC=tcc redo -j10 @@ -55,6 +59,7 @@ $ SLWEB_CC=tcc redo -j10 In the case of **tcc**, the tradeoff is that the debug information is limited compared to **gcc**, but the compilation time is significantly shorter. + ## Examples See the [`examples/`][examp] directory in this repository. @@ -138,6 +143,7 @@ this program. If not, see &lt;[https://www.gnu.org/licenses/][licen]&gt;. {made-by} {/main} + [aredo]: https://github.com/apenwarr/redo [examp]: https://git.sr.ht/~strahinja/slweb/tree/master/item/examples [imgmg]: https://imagemagick.org diff --git a/install.do b/install.do @@ -1,10 +1,11 @@ +#!/bin/sh redo-ifchange all PREFIX=${PREFIX:-/usr/local} BINDIR=$PREFIX/bin -DOCDIR=$PREFIX/share/doc/slweb +#DOCDIR=$PREFIX/share/doc/slweb MANDIR=$PREFIX/share/man/man1 install -d $BINDIR $DOCDIR $MANDIR install -m 0755 slweb $BINDIR -install -m 0644 slweb.pdf $DOCDIR +#install -m 0644 slweb.pdf $DOCDIR install -m 0644 slweb.1.gz $MANDIR diff --git a/uninstall.do b/uninstall.do @@ -1,7 +1,9 @@ +#!/bin/sh redo-always PREFIX=/usr/local BINDIR=$PREFIX/bin -DOCDIR=$PREFIX/share/doc/slweb +#DOCDIR=$PREFIX/share/doc/slweb MANDIR=$PREFIX/share/man/man1 -rm -f $BINDIR/slweb $DOCDIR/slweb.pdf $MANDIR/slweb.1.gz +#rm -f $DOCDIR/slweb.pdf +rm -f $BINDIR/slweb $MANDIR/slweb.1.gz