1
0
mirror of https://git.sr.ht/~sircmpwn/gmni synced 2024-11-23 04:51:59 +01:00
Commit Graph

82 Commits

Author SHA1 Message Date
Eyal Sawady
8bb1d81f53 gmnlm: handle CRLF line endings
Bare CRs are still printed as '.'.

Fixes https://todo.sr.ht/~sircmpwn/gmni/25
2020-09-24 15:33:57 -04:00
Eyal Sawady
963700d8d6 gmnlm: p: require whitespace before link number
In order to allow users to navigate to relative URLs starting with 'p'.
2020-09-24 14:57:15 -04:00
Eyal Sawady
5ad3f0aacc gmnlm: open bookmarks if started without URL 2020-09-24 14:57:14 -04:00
Eyal Sawady
b050b9e467 gmnlm: return to previous page on empty input 2020-09-24 14:42:40 -04:00
Charles E. Lehner
689fb8b470 Close fd after freeing SSL
BIO_free_all may trigger write to close the SSL connection
2020-09-24 11:45:59 -04:00
Eyal Sawady
59d19b9894 Fix bookmark save/open
Fix a segfault on bookmark save and a memory leak on bookmark open.
2020-09-24 11:37:23 -04:00
Eyal Sawady
f80e4037c2 Add 'r' to reload 2020-09-24 10:35:43 -04:00
Eyal Sawady
5fd43e8d02 gmni: use stdio to write body
Fixes https://todo.sr.ht/~sircmpwn/gmni/22
2020-09-24 10:33:54 -04:00
Eyal Sawady
d754f34e7e config.sh: add args for install directories 2020-09-24 10:33:29 -04:00
Eyal Sawady
0a03e6dadf Fix a bug causing some text to be duplicated
For example:

$ gmnlm gemini://gemini.circumlunar.space
[...]
11) A lissper.strangled.net/mirrorlist/ A lisssources
   t of mirrored services
[...]
2020-09-24 10:33:27 -04:00
Eyal Sawady
174fbd5d09 Fix memory leaks 2020-09-23 12:55:16 -04:00
Drew DeVault
0976b0e446 Fix search command 2020-09-23 12:55:12 -04:00
Drew DeVault
9f98e013a6 config.sh: remove project-specific code
Or reduce, really. Just makes this script easier to re-use elsewhere.
2020-09-23 10:20:32 -04:00
Arav K
9551d0a382 Add 'p' to view link URL without visiting
Answers https://todo.sr.ht/~sircmpwn/gmni/13 by adding a 'p' command
that, when given a (valid) link number, provides the URL that that link
leads to.
2020-09-23 09:12:53 -04:00
Eyal Sawady
be0cf0dfd1 Makefile: clean: remove objects 2020-09-23 09:12:48 -04:00
Leon Henrik Plickat
b25b4576e3 Correctly abort when launched with invalid URL
The return value of set_url() was not checked, meaning that when it
failed, gmnlm continued anyway, causing an assertion to fail and
subsequentially resulting in a segfault.
2020-09-22 09:07:20 -04:00
Arav K
60cf41e7dd Add 'H' to view all page history
This adds a command, 'H', to view all the URLs in the page history.  It
first prints backward URLs, then the current URL (marked with an
asterisk), followed by forward URLs.
2020-09-22 09:06:16 -04:00
Drew DeVault
39339c348f Fix issues with tofu.c 2020-09-21 22:22:18 -04:00
Eyal Sawady
d6777ec278 gemini_response_finish: handle null ssl connection 2020-09-21 22:22:09 -04:00
Eyal Sawady
e80d852a1b Makefile: silence gmni CCLD command 2020-09-21 20:57:56 -04:00
Drew DeVault
02f6af6615 Implement TOFU 2020-09-21 16:06:43 -04:00
Charles E. Lehner
30660fc160 Link with libraries before objects 2020-09-21 09:19:12 -04:00
Eyal Sawady
c7592c6a5c save_bookmark: fix bookmark file creation 2020-09-21 07:57:42 -04:00
Drew DeVault
eb2873b2eb gmnlm.c: add limits.h
Supposedly fixes OpenBSD
2020-09-21 07:56:20 -04:00
Drew DeVault
2e9d3c0bab Update README.md 2020-09-20 23:52:18 -04:00
Drew DeVault
601f900886 Implement bookmarks 2020-09-20 23:51:17 -04:00
Drew DeVault
852bc7198f Implement file:// URLs 2020-09-20 23:33:32 -04:00
Drew DeVault
d593635339 Swap quote character to > 2020-09-20 23:13:30 -04:00
Drew DeVault
4c12342bca README.md: use newer asciinema link 2020-09-20 22:38:31 -04:00
Drew DeVault
6f36d2a0fc gmnlm: add install target & man page 2020-09-20 22:37:44 -04:00
Drew DeVault
144693a3d0 Fix segfault moving to next result outside search 2020-09-20 22:34:27 -04:00
Drew DeVault
5799323f4c Implement preformatted text 2020-09-20 22:28:45 -04:00
Drew DeVault
59d43726bb Fix segfault on name resolution errors 2020-09-20 22:20:38 -04:00
Drew DeVault
bb696e6e28 Correct oversight which broke link following 2020-09-20 22:11:13 -04:00
Drew DeVault
f4a4be2513 Implement regex-based page search 2020-09-20 22:09:26 -04:00
Drew DeVault
28283bda98 Remove unnecessary TODO
There is no line length limit and authors are strongly discouraged from
hard-wrapping by the specification.
2020-09-20 21:53:08 -04:00
Drew DeVault
05cc8b85cd Add help message 2020-09-20 21:42:27 -04:00
Drew DeVault
d2fa1b4567 Allow user to navigate by typing in URL 2020-09-20 21:35:05 -04:00
Drew DeVault
1c9a6e6a35 Show [b]ack and [f]orward prompts contextually 2020-09-20 21:29:40 -04:00
Drew DeVault
46b5d74576 Expand wrapping to all token types 2020-09-20 21:26:23 -04:00
Drew DeVault
fed9c05619 Whitelist control sequences in wrap() 2020-09-20 21:02:17 -04:00
Drew DeVault
9bd1a7457e Remove obsolete TODO 2020-09-20 20:57:26 -04:00
Drew DeVault
a61a75f837 Implement basic word wrapping 2020-09-20 20:52:18 -04:00
Drew DeVault
e1d9773742 Indent # and ## to line up with text 2020-09-20 20:43:07 -04:00
Drew DeVault
678bff58ed Improve links
Removing the leading [ makes links 0-9 line up with the text body, which
is nice.
2020-09-20 20:13:22 -04:00
Drew DeVault
d0acd0f4d0 Add reduced-unicode mode 2020-09-20 20:11:48 -04:00
Drew DeVault
84df94447c Scale down image 2020-09-20 20:07:48 -04:00
Drew DeVault
c414388c0f README.md: add link to asciinema 2020-09-20 20:05:44 -04:00
Drew DeVault
563922a7e2 Merge normal mode & pagination prompts 2020-09-20 20:01:31 -04:00
Drew DeVault
b90888e718 README.md: add gmnlm 2020-09-20 19:58:34 -04:00