commit 3ce02e5183da68e017b572265d68f19fef59043c
parent 0513b91be1173b1ed43a0f1d28cf502a81267185
Author: René Wagner <rwagner@rw-net.de>
Date: Mon, 4 Jan 2021 19:05:25 +0100
rename to cgmnlm
Diffstat:
8 files changed, 60 insertions(+), 54 deletions(-)
diff --git a/Makefile b/Makefile
@@ -9,16 +9,16 @@ gmni: $(gmni_objects)
@printf 'CCLD\t$@\n'
@$(CC) $(LDFLAGS) -o $@ $(gmni_objects) $(LIBS)
-gmnlm: $(gmnlm_objects)
+cgmnlm: $(cgmnlm_objects)
@printf 'CCLD\t$@\n'
- @$(CC) $(LDFLAGS) -o $@ $(gmnlm_objects) $(LIBS)
+ @$(CC) $(LDFLAGS) -o $@ $(cgmnlm_objects) $(LIBS)
libgmni.a: $(libgmni.a_objects)
@printf 'AR\t$@\n'
@$(AR) -rcs $@ $(libgmni.a_objects)
doc/gmni.1: doc/gmni.scd
-doc/gmnlm.1: doc/gmnlm.scd
+doc/cgmnlm.1: doc/cgmnlm.scd
libgmni.pc:
@printf 'GEN\t$@\n'
@@ -46,10 +46,10 @@ libgmni.pc:
@printf 'SCDOC\t$@\n'
@$(SCDOC) < $< > $@
-docs: doc/gmni.1 doc/gmnlm.1
+docs: doc/gmni.1 doc/cgmnlm.1
clean:
- @rm -f gmni gmnlm libgmni.a libgmni.pc doc/gmni.1 doc/gmnlm.1 $(gmnlm_objects) $(gmni_objects)
+ @rm -f gmni cgmnlm libgmni.a libgmni.pc doc/gmni.1 doc/cgmnlm.1 $(cgmnlm_objects) $(gmni_objects)
distclean: clean
@rm -rf "$(OUTDIR)"
@@ -60,7 +60,7 @@ install: all install_docs
mkdir -p $(INCLUDEDIR)/gmni
mkdir -p $(LIBDIR)/pkgconfig
install -m755 gmni $(BINDIR)/gmni
- install -m755 gmnlm $(BINDIR)/gmnlm
+ install -m755 cgmnlm $(BINDIR)/cgmnlm
install -m755 libgmni.a $(LIBDIR)/libgmni.a
install -m644 include/gmni/gmni.h $(INCLUDEDIR)/gmni/gmni.h
install -m644 include/gmni/tofu.h $(INCLUDEDIR)/gmni/tofu.h
@@ -69,11 +69,11 @@ install: all install_docs
uninstall:
rm -f $(BINDIR)/gmni
- rm -f $(BINDIR)/gmnlm
+ rm -f $(BINDIR)/cgmnlm
rm -f $(LIBDIR)/libgmni.a
rm -rf $(INCLUDEDIR)/gmni
rm -f $(LIBDIR)/pkgconfig/libgmni.pc
rm -f $(MANDIR)/man1/gmni.1
- rm -f $(MANDIR)/man1/gmnlm.1
+ rm -f $(MANDIR)/man1/cgmnlm.1
.PHONY: clean distclean docs install
diff --git a/README.md b/README.md
@@ -1,23 +1,29 @@
-# gmni - A Gemini client
+# cgmnlm - A colorful Gemini line mode client
This is a [Gemini](https://gemini.circumlunar.space/) client. Included are:
- A CLI utility (like curl): gmni
-- A [line-mode browser](https://en.wikipedia.org/wiki/Line_Mode_Browser): gmnlm
+- A [line-mode browser](https://en.wikipedia.org/wiki/Line_Mode_Browser): cgmnlm
-Dependencies:
-
-- A POSIX-like system and a C11 compiler
-- OpenSSL
-- [scdoc](https://sr.ht/~sircmpwn/scdoc/) (optional)
-
-Features:
+## Features:
- Page history
- Regex searches
- Bookmarks
-[![Screenshot of the line-mode browser](https://l.sr.ht/7kaA.png)](https://asciinema.org/a/Y7viodM01e0AXYyf40CwSLAVA)
+### Modifications compared to upstream
+
+This project is of fork of https://git.sr.ht/~sircmpwn/gmni
+
+It includes the following modifications:
+- default 4 char indenting
+- colored headings & links
+
+## Dependencies:
+
+- A POSIX-like system and a C11 compiler
+- OpenSSL
+- [scdoc](https://sr.ht/~sircmpwn/scdoc/) (optional)
## Compiling
@@ -30,4 +36,4 @@ $ make
## Usage
-See `gmni(1)`, `gmnlm(1)`.
+See `gmni(1)`, `cgmnlm(1)`.
diff --git a/cgmnlm b/cgmnlm
Binary files differ.
diff --git a/config.sh b/config.sh
@@ -128,7 +128,7 @@ run_configure() {
install_docs="
mkdir -p \$(MANDIR)/man1
install -m644 doc/gmni.1 \$(MANDIR)/man1/gmni.1
- install -m644 doc/gmnlm.1 \$(MANDIR)/man1/gmnlm.1"
+ install -m644 doc/cgmnlm.1 \$(MANDIR)/man1/cgmnlm.1"
else
echo no
fi
diff --git a/configure b/configure
@@ -12,11 +12,11 @@ gmni() {
src/util.c
}
-gmnlm() {
- genrules gmnlm \
+cgmnlm() {
+ genrules cgmnlm \
src/client.c \
src/escape.c \
- src/gmnlm.c \
+ src/cgmnlm.c \
src/parser.c \
src/tofu.c \
src/url.c \
@@ -37,7 +37,7 @@ libgmni_pc() {
:
}
-all="gmni gmnlm libgmni.a libgmni.pc"
+all="gmni cgmnlm libgmni.a libgmni.pc"
run_configure
diff --git a/doc/cgmnlm.scd b/doc/cgmnlm.scd
@@ -0,0 +1,30 @@
+gmnlm(1)
+
+# NAME
+
+cgmnlm - colored Gemini line-mode browser
+
+# SYNPOSIS
+
+*cgmnlm* [-PU] [-j _mode_] [-W _width_] _gemini://..._
+
+# DESCRIPTION
+
+*cgmnlm* is an interactive line-mode Gemini browser.
+
+# OPTIONS
+
+*-j* _mode_
+ Sets the TOFU (trust on first use) configuration, which controls if the
+ client shall trust new certificates. _mode_ can be one of *always*,
+ *once*, or *fail*.
+
+*-P*
+ Disable pagination.
+
+*-U*
+ Disable conservative use of Unicode symbols to render Gemini layout
+ features.
+
+*-W* _width_
+ Sets the maximum width, in columns, of Gemtext pages.
diff --git a/doc/gmnlm.scd b/doc/gmnlm.scd
@@ -1,30 +0,0 @@
-gmnlm(1)
-
-# NAME
-
-gmnlm - Gemini line-mode browser
-
-# SYNPOSIS
-
-*gmnlm* [-PU] [-j _mode_] [-W _width_] _gemini://..._
-
-# DESCRIPTION
-
-*gmnlm* is an interactive line-mode Gemini browser.
-
-# OPTIONS
-
-*-j* _mode_
- Sets the TOFU (trust on first use) configuration, which controls if the
- client shall trust new certificates. _mode_ can be one of *always*,
- *once*, or *fail*.
-
-*-P*
- Disable pagination.
-
-*-U*
- Disable conservative use of Unicode symbols to render Gemini layout
- features.
-
-*-W* _width_
- Sets the maximum width, in columns, of Gemtext pages.
diff --git a/src/gmnlm.c b/src/cgmnlm.c