BlogMore comes with a built-in facility to post the generated static website to GitHub pages. The host of
blog.cpjobling.net is however a standard LAMP) stack
which is updated by recursively copying the contents of the public directory to a folder blog.cpjobling.net on the host. That folder has been registered as the base directory for the DNS record.
The easiest way to do that is using rsync over ssh.
I used the advice given in How to Setup Rsync without password with SSH on UNIX / Linux? to set up my publish.sh script:
#!/usr/bin/env bash
cd ~/blogs/blog.cpjobling.net # local files
blogmore build --clean-first # build blog using default`posts` and config `blogmore.yml`
echo "Syncing files using SSH (see https://superuser.com/questions/555799/how-to-setup-rsync-without-password-with-ssh-on-unix-linux)"
rsync -avz --delete -e ssh public/ user@host.hosting.com:blog.cpjobling.net
âšī¸ Note
I use the --clean-first flag for the blogmore build command and --delete in the rsync command to ensure that no orphan files end up on the server.