💾 Archived View for rkta.srht.site › w3m-gemini.gmi captured on 2023-11-04 at 11:21:11. Gemini links have been rewritten to link to archived content
View Raw
More Information
⬅️ Previous capture (2023-09-08)
➡️ Next capture (2023-12-28)
🚧 View Differences
-=-=-=-=-=-=-
Rene Kita's weblog
Blog[0] About[1] RSS[2] Links[3]
Gemini support for w3m
2023-01-23
_tl;dr_ I wrote a patch[4] to add Gemini support to w3m.
I started adding Gemini[5] support to w3m[6]. As a user w3m is a great piece of software. It has good HTML support and speaks nearly all other protocols you'll come across while surfing the web#0. It bothered me that I had to use a different tool when I came across a gemini link. Also, you don't often get the chance to add a new protocol to a 28 year old piece of software.
This is still Work in Progress, but has enough features to be usable.
Features
- 'Clickable' links
- Folds lines at word boundary
- Pressing 'v' (VIEW) (lynx: '\' SOURCE) on a text/gemini buffer toggles between rendered and text/plain view
- Follows redirects
- Permanently accept self-signed certificates (Trust On First Use)
- Partial support for INPUT (still quoting issues)
- Use command GEMINIZE (via Esc-c) to render text/plain as text/gemini
To-do
- Fix quoting of special chars in URL for INPUT
- Do not overwrite known_hosts/accepted self-signed certificates if they were modified by another instance of w3m
- Clean up code (Current stage: "Make it work"; next stage: "Make it good")
- Add a configure switch to enable/disable Gemini support for the compile stage
- Make handling of 'Advanced line types' (Headings, lists and quotes) configurable through options
How to
- Get the w3m sources: git clone https://github.com/tats/w3m
- Change into the new directory: cd w3m
- Download the patch[7]: wget https://rkta.de/assets/gemini.patch
- Apply the patch: patch < gemini.patch
- Get the build dependencies: apt-get build-dep w3m (or the equivalent of your distro)
- Configure and build: ./configure && make
- Try: ./w3m gemini://rkta.srht.site/w3m-gemini.gmi
I've you need help or just want to leave feedback send me an email or join #w3m[8] on irc.libera.chat[9]
Changelog
2023-10-28:
Make sure the correct buffer type is set
2023-08-13:
Fix a bug that added empty entries to known_hosts
Simplify the code a bit
Let geminize command show up in help menu
2023-03-26:
Update the patch to indent blockquotes with four spaces
- 0: Another not supported protocol is finger, let's see what happens when gemini support is finished
E-mail: mail@rkta.de[10] IRC: #rkta[11] on Libera.Chat[12]
Copyright © 2017-2023 Rene Kita
[0] Blog
[1] About
[2] RSS
[3] Links
[4] patch
[5] Gemini
[6] w3m
[7] patch
[8] #w3m
[9] irc.libera.chat
[10] mail@rkta.de
[11] #rkta
[12] Libera.Chat