How to SSH and edit your .gmi files on the Command Line


Using the web version of flounder online is great and very intuitive, but I am a geek and like to test new methods of doing everyday tasks.


I am trying to reduce my exposure to the web due to it's toxic nature now days.


Thankfully flounder.online has a way to use SSH to get stuff done on the command line. This will let me do one less thing on the www and spend more time on Gemini.


So this post covers how to:


Open your prefered terminal and create the folder where your flounder files will be stored.


mkdir <your-local-folder-for-gemini>

cd <your-local-folder-for-gemini>



Connect to your account


sshfs <your-username>@flounder.online:/ <your-local-folder-for-gemini>/ -p 2024 -p 2024


<enter-password>


You should now be connected via ssh to your flounder.online account. Entering ls will list your files and folders in your account.



Editing your files


Now cd into the directory you created for mirroring your Gemini Space.


To edit your index page:


nano index.gmi


To create a new Gemlog entry:


cd gemlog


nano <date>.gmi (enter the date here, not <date>)

To create files and directories, you can user the normal shell commands such as touch, mkdir, rmdir and editing with the text editor of your chosing.


Post connection


My workflow is to open a byobu session(like screen) and start editing my files. Your preferences for navigating and editing may vary, but the princilpal is the same.


If you would rather use a GUI file manager or editor, then feel free to do that by navigating to your Gemini folder. Create and edit in your synced ssh folder as needed.


You may notice a slight lag in opening and saving files, that is because you are doing so from a remote location; it's only a fraction of a second, but I'm in no hurry, actually I enjoy that it takes time and things don't move at a break-neck speed on Genisis.


Creating folders and files is super-easy, it can be done as mentioned above; via CLI or GUI.


Happy SSH'ing into Genisis.


Home



/gemlog/