From 6820df7845721b18ff59dffba9d33d13cdb0370e Mon Sep 17 00:00:00 2001 From: Dante Catalfamo Date: Thu, 18 Jun 2020 01:15:26 -0400 Subject: More updates for blog setup post --- content/posts/how-this-blog-works/index.org | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'content/posts/how-this-blog-works') diff --git a/content/posts/how-this-blog-works/index.org b/content/posts/how-this-blog-works/index.org index aa1f329..62c5bb9 100644 --- a/content/posts/how-this-blog-works/index.org +++ b/content/posts/how-this-blog-works/index.org @@ -1,8 +1,8 @@ -#+TITLE: How This Blog Is Set Up +#+TITLE: Creating Self-Hosted Hugo Blog with OpenBSD #+DATE: 2020-06-17T21:03:26-04:00 #+DRAFT: true #+DESCRIPTION: -#+TAGS[]: hugo openbsd emacs +#+TAGS[]: hugo openbsd #+KEYWORDS[]: #+SLUG: #+SUMMARY: @@ -182,6 +182,7 @@ through how I run by blog. #+BEGIN_SRC shell #!/bin/sh + set -e cd '$(dirname "$0")' hugo @@ -190,6 +191,9 @@ through how I run by blog. Going through it line by line: + - ~set -e~ Tells the shell to exit if any commands fail instead of + continuing execution. If ~hugo~ has a problem and exits with an + error, don't sync with the server. - ~cd '$(dirname "$0")'~ Changes to the script's directory. This is used in case you're running it from somewhere else. - ~hugo~ Compile the website into static files located in the @@ -214,7 +218,7 @@ through how I run by blog. =blog= on server =lambda.cx=, syncing files with the =/var/www/htdocs/lambda.cx/blog= directory. - The reason to use =rsync= here instead of something like =scp= is - that =rsync= won't copy files it doesn't need to, so if 3/4 of - the files didn't change when you updated the blog, it won't waste - time re-uploading them. + The reason to use =rsync= here instead of something like =scp= is + that =rsync= won't upload files it doesn't need to, so if 3/4 of + the files didn't change when you updated the blog, it won't waste + time re-uploading them. -- cgit v1.2.3