Permalink
Browse files

Enhance Makefile and Netlify deployment (#91)

  • Loading branch information...
khos2ow authored and luizdepra committed Oct 4, 2018
1 parent 9118a00 commit dcefc200ee7a871c018c0f245b172c8b2f70f369
Showing with 19 additions and 9 deletions.
  1. 0 {exampleSite → }/.hugo/version
  2. +10 −9 Makefile
  3. 0 {exampleSite → }/hugow
  4. +9 −0 netlify.toml
File renamed without changes.
@@ -1,17 +1,18 @@
.PHONY: release build demo clean
.PHONY: prepare release build demo clean

build: clean
mkdir -p demo/themes/hugo-coder
rsync -av exampleSite/ demo
rsync -av --exclude='demo' --exclude='exampleSite' --exclude='.git' . demo/themes/hugo-coder

demo: build
build: prepare
./hugow --source demo

cd demo && ./hugow serve -D
demo: prepare
./hugow server --buildDrafts --source demo

release: build
cd ./demo && ./hugow
rm -rf ./resources && cp -r ./demo/resources ./resources

prepare: clean
mkdir -p demo/themes/hugo-coder
rsync -av exampleSite/ demo
rsync -av --exclude='demo' --exclude='exampleSite' --exclude='.git' . demo/themes/hugo-coder

clean:
rm -rf demo
File renamed without changes.
@@ -0,0 +1,9 @@
[build]
publish = "demo/public"
command = "make prepare && hugo --source demo"

[context.deploy-preview]
command = "make prepare && hugo --source demo --buildFuture --buildDrafts --baseURL $DEPLOY_PRIME_URL"

[context.deploy-preview.environment]
HUGO_VERSION = "0.49"

0 comments on commit dcefc20

Please sign in to comment.