-- Leo's gemini proxy

-- Connecting to warmedal.se:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini; lang=en

My Local Branch of AV-98


The first gemini browser I tried was AV-98, and it's still the one I use on my computer. Solderpunk wrote it, but he's not much online these days and it hasn't been updated in a very long time.


AV-98 on tildegit.


Meanwhile, I've made a couple of local changes. They're really small, but I feel that they've made my browsing experience better.


I've changed the prompt to show which client cert is active (when one is).

I replaced GUS with geminispace.info as the search engine, since GUS is now defunct. I still use the 'gus' command for search, though.


Here's the code diff (I have a feeling a screen reader will vomit at this; it's the output of the git diff command):


$ git diff master local-version
diff --git a/av98.py b/av98.py
index f74b532..ff94315 100755
--- a/av98.py
+++ b/av98.py
@@ -241,7 +241,7 @@ class GeminiClient(cmd.Cmd):
             os.makedirs(self.config_dir)

         self.no_cert_prompt = "\x1b[38;5;76m" + "AV-98" + "\x1b[38;5;255m" + "> " + "\x1b[0m"
-        self.cert_prompt = "\x1b[38;5;202m" + "AV-98" + "\x1b[38;5;255m" + "+cert> " + "\x1b[0m"
+        self.cert_prompt = "\x1b[38;5;202m" + "AV-98" + "\x1b[38;5;255m"
         self.prompt = self.no_cert_prompt
         self.gi = None
         self.history = []
@@ -269,7 +269,7 @@ class GeminiClient(cmd.Cmd):
         self.options = {
             "debug" : False,
             "ipv6" : True,
-            "timeout" : 10,
+            "timeout" : 600,
             "width" : 80,
             "auto_follow_redirects" : True,
             "gopher_proxy" : None,
@@ -1066,7 +1066,7 @@ you'll be able to transparently follow links to Gopherspace!""")
     def _activate_client_cert(self, certfile, keyfile):
         self.client_certs["active"] = (certfile, keyfile)
         self.active_cert_domains = []
-        self.prompt = self.cert_prompt
+        self.prompt = self.cert_prompt + "+" + os.path.basename(certfile).replace('.crt','') + "> " + "\x1b[0m"
         self._debug("Using ID {} / {}.".format(*self.client_certs["active"]))

     def _deactivate_client_cert(self):
@@ -1347,8 +1347,8 @@ Use 'ls -l' to see URLs."""
         self.page_index = 0

     def do_gus(self, line):
-        """Submit a search query to the GUS search engine."""
-        gus = GeminiItem("gemini://gus.guru/search")
+        """Submit a search query to the geminispace.info search engine."""
+        gus = GeminiItem("gemini://geminispace.info/search")
         self._go_to_gi(gus.query(line))

     def do_history(self, *args):

Given time and inclination I might make more changes.


Would anyone else be interested in this? I could always push this to a repo of my own and maintain as a fork if there's any interest from others to use or contribute.


-- CC0 ew0k, 2021-05-03

-- Response ended

-- Page fetched on Sat May 4 14:06:15 2024