Paul Sutton

Gophermap

Gopher 5: Troubleshooting Gophermap

As previously discussed, a gophermap is a text file. It does however require specific formatting.

When adding links to a document, you need to ensure the space between the label and filename is a tab and not spaces. I previously discussed HOW TO set up an editor to treat pressing tab as an actual tab character.

If things are not working properly, there are several things you can try in the first instance.

IParticle Interactions	particle_chart.jpg
  • You can delete the area what is between the label Particle Interactions and filename particle_chart.jpg and reinsert a tab
  • Delete everything after the label, (well use cut) then paste it back in, then insert a tab

This sometimes fixes any issues, it may seem strange in the gophermap that some tabs appear small and others appear longer (as if they are equivalent of 4 spaces) this seems normal.

If you want to make sure of what is there, you can use a hex editor to examine deeper in to a file.

Hex editor

What you are looking for are the following

Within ASCII :

  • Tab is 09 decimal, Hex 09
  • Space is 32 decimal, Hex 20 (Two Zero)

Find where tabs are inserted, and check the hex is displaying 09, It may look by the text field on the right that some characters appear as periods, this is I think due to the fact that the editor needs to have something to represent what is there. If that makes sense.

gopher gopher://vern.cc/1/~zleap

Tags

#Gopher,#Gophermap,#TroubleShooting,#Tab,#Space,#Hex,#HexEditor


Mastodon ShellLabs Join Mastodon
AI statement : Consent is NOT granted to use the content of this blog for the purposes of AI training or similar activity. Consent CANNOT be assumed, it has to be granted.

Donate using Liberapay

Gopher 4: Anatomy of a gopermap

A gophermap is a plain text file, with a specific format to tell gopher how to interpret the various elements.

I will try and explain my own gophermap fille below.

Firstly, we have a banner, this can be gernerated from various websites, for example :-

i ______     _____    _    ____     	(NULL)  0	   
i|__  / |   | ____|  / \  |  _ \    	(NULL)  0	     
i  / /| |   |  _|   / _ \ | |_) |   	(NULL)  0	
i / /_| |___| |___ / ___ \|  __/    	(NULL)  0	
i/____|_____|_____/_/   \_\_|       	(NULL)  0	   

After which I have put a brief introduction and links to text files that are also stored along side the gophermap.

My name is Paul. This is my gopherspace on vern.cc. 

INFO

0About me	about.txt
0Contact	contact.txt
0Blog	blog.txt

So two IMPORTANT things here, the 0 at the start of the line tells gopher to link to a text file. See link 1 for an explanation of what to put at the start of a line for linking to different types of resources.

We then have a name of what we are linking to, then a then the filename. You MUST set up your editor so it interprets tabs properly.

Alongside the text files, I have a PDF file and a link to the source LaTeX file (which is plain text), I have also linked to a shell script and a CSV data file.

PROJECTS

Command reference for the Joe Text Editor

9Joe Command Reference(pdf)	jcr.pdf
0LaTeX Source for above	main.tex

Weather logger,  this is a simple bash script, that uses the ascii weather program to obtain weather information, and log this with time and date.   I have it running on a Raspberry Pi, so when plugged in, it logs the data to a CSV (comma separated values) file. 

0Weather logger bash Script	logweather.sh
0Output file (CSV)	weather.csv

Note, you will probably need to set permissions on logweather.sh to +x

While we can't display pictures / graphics in gopher, we can link to such files so they can be downloaded. Note below, I have these files in a directory / folder alongside my gophermap. so, need to include the path to the file.

  /pictures/tux.jpg

GRAPHICS

ITux	/pictures/tux.jpg
ISouth West Map	/southwest1.png

We can also link to other gopher sites and resources

GOPHER LINKS

0Vern.cc	gopher://vern.cc/	70
0Why is Gopher Still Relevant?	/gopher/relevance.txt	gopher.floodgap.com	70

While it is possible to link to a website URL I have decided to link to a markdown file, that has weblinks within. Users will need to copy / paste the url or download and open as a markdown file.

WEB LINKS

I have sorted into categories

0Astronomy & Space	AstroSpace.md
0Discussion Forums	Discussion.md

Links

1 Structure of a gophermap 2 Vern.cc 3 Vern Matrix

Tags

#Gopher,#Gophermap


Mastodon ShellLabs Join Mastodon
AI statement : Consent is NOT granted to use the content of this blog for the purposes of AI training or similar activity. Consent CANNOT be assumed, it has to be granted.

Donate using Liberapay