I've noticed several people I follow on Neocities mentioning having issues with editing pages, or downloading site backups. I've experienced issues with saving files in the online editor not working properly in the past, so I moved to an offline editing workflow and set up some tools to simplify publishing my changes to Neocities and tracking version history with Git.

Editing Pages

I use Sublime Text to edit my posts because of its package system. The packages are what allow me to edit, backup, and publish my site updates quickly and all within Sublime.

Once I installed Sublime, I installed the Package Control and Open in Default Application packages. Package Control allows the installation of other packages, and Open in Default Application allows easy opening of pages in my browser from within Sublime. Finally, I downloaded a site backup and opened that folder in Sublime so that I could access all the files quickly. With all this done, I could edit my site easily offline, but I still needed a way to back up old versions and publish my changes to Neocities.

Version Control

I use Git to retain access to old versions of my site in case I ever need them. It also allows me to set up a similar editing environment on multiple computers and keep them all up to date without downloading site backups. I won't go over the process for setting up a Git repo, as there are plenty of guides out there already.

Once I had my Git repo set up and pushing to GitHub working, I installed the Git package so that I could commit and push to GitHub within Sublime via its command palette.

Publishing to Neocities

Neocities provides a useful tool for publishing site updates: the Neocities CLI. That link has instructions for installation that I followed. Once it's installed, running any subcommand for the first time prompted me to log in. With that done, running "neocities push ." from the root directory of my site will automatically publish any new pages and publish updates for any that have changed.

Finally, I installed the Terminus package in Sublime and bound "alt+`" to toggle the terminus panel. That allows quick access to a terminal already open to the directory I have opened in Sublime (in my case, the root directory of my site). So, I can hit alt+` and run "neocities push ." to quickly publish my changes.

Final Workflow

With all this set up, my workflow looks something like this: Make new pages or edit existing ones, view my changes in my browser to make sure they look good, and repeat until I'm ready to publish. Then I'll commit my changes in Git and push them to GitHub. With my backup done, I then publish my site update to Neocities using the Neocities CLI. Importantly, all of this is done within Sublime, so I don't have to open a bunch of windows to just write something quickly.