|
|
@ -10,13 +10,15 @@ preview: |
|
|
add_article: |
|
|
add_article: |
|
|
@echo "Enter Article Title: " |
|
|
@echo "Enter Article Title: " |
|
|
@read title;\
|
|
|
@read title;\
|
|
|
mkdir -p contents/is/writing/about/$$title;\
|
|
|
|
|
|
cat base.md | sed s/{title}/$$title/g | sed s/{date}/`date "+%Y-%m-%d"`/g> contents/is/writing/about/$$title/index.md;\
|
|
|
|
|
|
emacs contents/is/writing/about/$$title/index.md |
|
|
|
|
|
|
|
|
dir=`echo $$title | sed "s/ /-/g"`;\
|
|
|
|
|
|
mkdir -p contents/is/writing/about/$$dir;\
|
|
|
|
|
|
cat base.md | sed "s/{title}/$$title/g" | sed s/{date}/`date "+%Y-%m-%d"`/g> contents/is/writing/about/$$dir/index.md;\
|
|
|
|
|
|
emacs contents/is/writing/about/$$dir/index.md |
|
|
|
|
|
|
|
|
remove_article: |
|
|
remove_article: |
|
|
@echo "Enter Article Title: " |
|
|
@echo "Enter Article Title: " |
|
|
@read title;\
|
|
|
@read title;\
|
|
|
rm -rf contents/is/writing/about/$$title |
|
|
|
|
|
|
|
|
dir=`echo $$title | sed "s/ /-/g"`;\
|
|
|
|
|
|
rm -rf contents/is/writing/about/$$dir |
|
|
|
|
|
|
|
|
.PHONY: build clean preview add_article remove_article |
|
|
.PHONY: build clean preview add_article remove_article |