Further TOFU work
Certificates now saved in collection. Still running into the same issue with some sites served off of gmnisrv but difficult to figure out what exactly is going wrong.
Working on fixing TOFU error. This has stopped working on some sites the second time they are fetched in a session. I believe I just need to persist the certs sent and send them with the SslStream.
Link description breakout
In progress work on showing the description of a link rather than the url from the page. Unsure if this will be continued.
FIX: No space between => and the link text sometimes caused a crash.
Encapsulating the split at space between link markup and the link reference in a try block fixes the crash.
FIX: Old page links were being brought over if no new host found
FIX: Fixed crash on host that can't be found
Null checks to prevent this.
FIX: Remove leading bytes in README
This was causing issues with sr.ht showing the first line header correctly.
Update: Interactive mode now launched if no arguments passed.
Update to launch interactive mode automatically if no arguments are passed to the program. README update to match.
FIX: Local links with leading slashes work
Previously a local link on the same server would cause the address parser to double up sometimes.
Basic line wrapping for this.
Better search & redirect handling.
Detangled some of the spaghetti stuff to use less direct references. Now search works correctly. Also took the chance to handle all redirects the same as I don't keep a permanent record of them anyway.
Catch host errors & blank request errors.
TCPClient now tries the connection rather than connecting in the constructor. This lets me output an error to be the response if host can't be found. Also changed things around so a blank url doesn't fetch a new page, it just returns the current page.
Work on search
It works but there is a loop where after fetching the search results it clears and goes back to the search page. Just an ordering thing.
Redirects should automatically redirect to the new location. There is an issue with redirects on gemini.circumlunar.space where going to the base without the trailing slash leads to an infinite 31 loop despite fetching at a 20 at some point. I need to figure out where I'm handling this wrong.
Better local link handling
Put the content type at the top with a break after before printing the file. This makes more sense.
The curl use is not currently working, and I really need to figure out why.
Better handling of relative links
Relative links still not perfect. Still runs into issues if the file has a . somewhere but that isn't indicating the server in the relative links. But completely possible to use to look at links in a site now.
Working more. There was a bit issue where I was fetching the pages everytime. BIG MISTAKE. Sorry ddevault
Cycle through links and go to
This almost works. Doesn't yet correctly work on relative links.