/site

Primary LanguageHTML

Source of https://mono0926.com

Structure

Workflow

  • Executing by Alfred Workflows is recommended.
  • These scripts should be improved...

Post a new article

SOURTH_PATH='/Documents/Git/Private/site'
cd ~/$SOURTH_PATH
git pull
POST_PATH=$(hugo new post/$1.md)
POST_PATH=$(echo $POST_PATH | sed -e "s/ created//")
open $POST_PATH

Preview

SOURCE_PATH='/Documents/Git/Private/site'
cd ~/$SOURCE_PATH
open http://localhost:1313/
hugo server --buildDrafts --watch

Deploy

push_changes() {
    git add -A
    git commit -m "Deployed via workflow."
    git pull
    git push origin master
}

SOURCE_PATH='/Documents/Git/Private/site'
cd ~/$SOURCE_PATH
hugo
cd public
push_changes
cd -
cd themes/hugo-mono
push_changes
cd -
push_changes