From 976e6e9df2b9aa50aadb22a3216a0871354f5160 Mon Sep 17 00:00:00 2001 From: nek0 Date: Sun, 2 Dec 2018 13:16:06 +0100 Subject: [PATCH] enable foreign access --- README.md | 50 ++++++++++++++++++++++++++++++++++++++++++++++++-- src/Main.hs | 2 +- 2 files changed, 49 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 735efc9..c902148 100644 --- a/README.md +++ b/README.md @@ -2,14 +2,60 @@ The source files for the website. +## Dependencies + +This site is built using [Hakyll](https://jaspervdj.be/hakyll). +To be able to build and run this, you need to install the following: + +* ghc +* cabal-install +* alex +* happy +* zlib1g-dev + ## New post To write new posts just invoke `newpost.sh`. This will guide you through the process. After you have written and saved the new post, add the post (you can find it in -`site/posts/`) to the repo, commit and push it. Ping me at to -rebuild the blog. +`site/posts/`) to the repo, commit and push it. + +## Build and deploy + +### NixOS + +After cloning the repo and changing into the repo directory, +you can invoke + +```bash +nix-shell shell.nix +``` + +to build a shell with +all dependencies in it. After that, you invoke + +```bash +cabal new-run -- chaoszone build && cabal new-run -- chaoszone deploy +``` + +to build the static sites and eploy them in one step. + +### Other \*nix + +After cloning the repo, you change into the directory and invoke + +``` +cabal new-update +``` + +to initialize your cabal package repository list. After that you can run + +```bash +cabal new-run -- chaoszone build && cabal new-run -- chaoszone deploy +``` + +to build the static sites and eploy them in one step. ## Altering building process diff --git a/src/Main.hs b/src/Main.hs index d0a7e6a..13dbe02 100644 --- a/src/Main.hs +++ b/src/Main.hs @@ -139,7 +139,7 @@ postCtx = -------------------------------------------------------------------------------- config :: Configuration config = defaultConfiguration - { deployCommand = "rsync --del --checksum -arve 'ssh -p 5555 ' _site/* nek0@chelnok.de:/home/nek0/www/chaoszone" + { deployCommand = "rsync --del --checksum -arve 'ssh -p 5555 ' _site/* chaoszone@chelnok.de:/home/chaoszone/www/chaoszone" } --------------------------------------------------------------------------------