chore: add make target to create new post
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Robert Kaussow 2022-03-13 19:53:14 +01:00
parent 96adcf78f5
commit 32e60de8ea
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
2 changed files with 19 additions and 0 deletions

View File

@ -3,6 +3,7 @@ THEME_VERSION := v0.16.1
THEME := hugo-geekblog
BASEDIR := .
THEMEDIR := $(BASEDIR)/themes
YEAR := $(shell date +"%Y")
.PHONY: all
all: doc
@ -18,3 +19,8 @@ doc-assets:
.PHONY: clean
clean:
rm -rf $(THEMEDIR)
.PHONY: hugo-new
hugo-new:
hugo new posts/$(YEAR)/$(title)/index.md ; \
mkdir -p content/posts/$(YEAR)/$(title)/images

13
archetypes/posts.md Normal file
View File

@ -0,0 +1,13 @@
---
title: "{{ replace .Name "-" " " | title }}"
date: {{ .Date }}
authors:
- robert-kaussow
tags: []
resources:
- name: feature
src: "images/feature.jpg"
params:
anchor: Center
credits: ""
---