This commit is contained in:
parent
b93c6eda68
commit
f1f499e501
|
@ -6,3 +6,4 @@ package-json.lock
|
||||||
_site
|
_site
|
||||||
node_modules
|
node_modules
|
||||||
_drafts
|
_drafts
|
||||||
|
.CommitMessage.txt
|
||||||
|
|
4
local.sh
4
local.sh
|
@ -2,10 +2,12 @@
|
||||||
cd "$( dirname "$( realpath "$0" )" )"
|
cd "$( dirname "$( realpath "$0" )" )"
|
||||||
|
|
||||||
[ "$1" = "update" ] && \
|
[ "$1" = "update" ] && \
|
||||||
git add . && git commit -m ": $2" && git push
|
Message="$( [ -n "$2" ] && echo "$2" || cat .CommitMessage.txt )"
|
||||||
|
git add . && git commit -m ": ${Message}" && git push
|
||||||
|
|
||||||
[ "$1" = "newpost" ] && [ -n "$2" ] && [ -n "$3" ] && \
|
[ "$1" = "newpost" ] && [ -n "$2" ] && [ -n "$3" ] && \
|
||||||
mkdir -p "./assets/media/games/$2" && \
|
mkdir -p "./assets/media/games/$2" && \
|
||||||
|
echo "Add $2 [$3]" > .CommitMessage.txt && \
|
||||||
cat << [EOF] > "./_posts/$3-$2.md"
|
cat << [EOF] > "./_posts/$3-$2.md"
|
||||||
---
|
---
|
||||||
layout: "post"
|
layout: "post"
|
||||||
|
|
Loading…
Reference in New Issue