GMI100(1)

NAME
gmi100 - Gemini CLI protocol client written in 100 lines of ANSI C.

SYNOPSIS
gmi100 [PAGER]

gmi100> [ACTION]

DESCRIPTION
Other similar Gemini client projects written in few lines of code successfully shows how simple Gemini protocol is. This code is far from straight forward. But I had a different goal in mind. I tried to pack as much as possible in 100 lines of ANSI C. Initially I struggled to fit simple TLS connection in such small space but eventually I ended up with CLI client capable of efficient navigation between capsules of Gemini space.

ACTIONS

N   Number of link on current capsule

r   Refresh current capsule

u   Go "up" in URL directory path

b   Go back in browsing history

c   Print current capsule URI

q   Quit

?   Search - kennedy.gemi.dev/search is used by default

!   Shell command prefix - run it on current capsule

USAGE EXAMPLES

gmi100 cat
    Using "cat" as pager

gmi100> geminiprotocol.net
    On prompt: go to capsule

gmi100> 3
    On prompt: go to link number 3 of current capsule

gmi100> !nsxiv
    On prompt: open file of current URL with nsxiv (image)

HISTORY
After you run the program it will open or create history .gmi100 file. Then every page you visits that is not a redirection to other page and doesn't ask you for input will be appended at the end of history file. File is never cleaned up by program itself to make history persistent between sessions but that means cleaning up browsing history is your responsibility. But this also gives you an control over history file content. You can for example append some links that you want to visit in next session to have easier access to them just by running program and pressing "b" which will navigate to last link from history file. During browsing session typing "b" in program prompt for the first time will result in navigation to last link in history file. Then if you type "b" again it will open second to last link from history. But it will also append that link at the end. You can input "b" multiple times and it will always go back by one link in history and append it at then end of history file at the same time. Only if you decide to navigate to other page by typing URL or choosing link number you will break that cycle. Then history "pointer" will go back to the very bottom of the history file.

AUTHOR
irek@gabr.pl