Introduction
Introduction Statistics Contact Development Disclaimer Help
use built-in col flag instead - libgcgi - REST library for Gopher
git clone git://bitreich.org/libgcgi git://hg6vgqziawt5s4dj.onion/libgcgi
Log
Files
Refs
Tags
README
LICENSE
---
commit d0bfec3b39e68a034364d01e1bdb4d37d605b839
parent 7a737dac78b68760118454337c2caeb6906fd90c
Author: Josuah Demangeon <[email protected]>
Date: Thu, 4 Aug 2022 00:04:19 +0200
use built-in col flag instead
Diffstat:
M Makefile | 2 +-
M README | 18 +++++++++---------
M libgcgi.3 | 6 +++---
3 files changed, 13 insertions(+), 13 deletions(-)
---
diff --git a/Makefile b/Makefile
@@ -8,7 +8,7 @@ clean:
rm -f *.o index.cgi
README: libgcgi.3
- mandoc -Tutf8 libgcgi.3 | col -b | expand | sed '1h; $$g' >$@
+ mandoc -Tutf8 libgcgi.3 | col -bx | sed '1h; $$g' >$@
index.cgi: index.c libgcgi.c libgcgi.h
${CC} ${LDFLAGS} ${CFLAGS} -o $@ index.c libgcgi.c ${LIBS}
diff --git a/README b/README
@@ -70,8 +70,8 @@ DESCRIPTION
Content Generation
According to geomyidae(8) behavior, the output format will be:
- • a raw gophermap if the binary is “index.cgi”,
- • a geomyidae(8) ‘gph’ format if the binary is “index.dcgi…
+ • a raw gophermap if the binary is “index.cgi”,
+ • a geomyidae(8) ‘gph’ format if the binary is “index.dcgi”.
void gcgi_fatal(char *fmt, ...)
Prints an error message formatted by fmt and exit(3) the program
@@ -96,9 +96,9 @@ DESCRIPTION
Variable List Handling
A common data format is used for handling lists of variables:
- • For parsing a simple text-based database format and writing it…
- • For storing the parsed query string in gcgi_gopher_query.
- • For passing variables to expand in the templates.
+ • For parsing a simple text-based database format and writing it back.
+ • For storing the parsed query string in gcgi_gopher_query.
+ • For passing variables to expand in the templates.
void gcgi_set_var(struct gcgi_var_list *vars, char *key, char *val)
Overwrite with val the value of a variable matching key of vars.
@@ -117,11 +117,11 @@ DESCRIPTION
void gcgi_read_var_list(struct gcgi_var_list *vars, char *path)
Store all variables from path onto variables in vars. The file
format is similar to RFC822 messages or HTTP headers:
- • One line per variable, with a key=value format.
- • The key is everything at the beginning of the line unt…
+ • One line per variable, with a key=value format.
+ • The key is everything at the beginning of the line until the
occurence of “:”.
- • The value is everything after “: ”.
- • After the list of variables, an empty line declares th…
+ • The value is everything after “: ”.
+ • After the list of variables, an empty line declares the body
of the message, which continues until the end and is stored in
a “text” key.
diff --git a/libgcgi.3 b/libgcgi.3
@@ -103,7 +103,7 @@ struct is an array of
According to
.Xr geomyidae 8
behavior, the output format will be:
-.Bl -bullet -compact -width x
+.Bl -bullet -compact -width 1n
.
.It
a raw gophermap if the binary is
@@ -170,7 +170,7 @@ are NULL, default values will be used.
.Ss Variable List Handling
.
A common data format is used for handling lists of variables:
-.Bl -bullet -compact -width x
+.Bl -bullet -compact -width 1n
.It
For parsing a simple text-based database format and writing it back.
.It
@@ -215,7 +215,7 @@ Store all variables from
onto variables in
.Fa vars .
The file format is similar to RFC822 messages or HTTP headers:
-.Bl -bullet -compact -width x
+.Bl -bullet -compact -width 1n
.It
One line per variable, with a key=value format.
.It
You are viewing proxied material from bitreich.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.