Pelican Build
This commit is contained in:
parent
03c9e3179e
commit
fb4cd9b03e
2 changed files with 8 additions and 22 deletions
17
action.yml
17
action.yml
|
@ -11,22 +11,15 @@ runs:
|
||||||
image: 'Dockerfile'
|
image: 'Dockerfile'
|
||||||
|
|
||||||
inputs:
|
inputs:
|
||||||
GH_PAGES_BRANCH:
|
|
||||||
description: 'override the default `gh-pages` deployment branch'
|
|
||||||
required: false
|
|
||||||
default: 'gh-pages'
|
|
||||||
GH_PAGES_CNAME:
|
|
||||||
description: 'specify the custom domain configured for the output branch'
|
|
||||||
required: false
|
|
||||||
default: none
|
|
||||||
PELICAN_CONFIG_FILE:
|
PELICAN_CONFIG_FILE:
|
||||||
description: 'override the default `pelicanconf.py` config file'
|
description: 'override the default `publishconf.py` config file'
|
||||||
required: false
|
required: false
|
||||||
default: pelicanconf.py
|
default: publishconf.py
|
||||||
PELICAN_CONTENT_FOLDER:
|
PELICAN_CONTENT_FOLDER:
|
||||||
description: 'override the default `content` content folder'
|
description: 'override the default `content` content folder'
|
||||||
required: false
|
required: false
|
||||||
default: content
|
default: content
|
||||||
PELICAN_THEME_FOLDER:
|
PELICAN_OUTPUT_FOLDER:
|
||||||
description: 'setup the theme folder with package.json file, is required if you need install node modules'
|
description: 'override the default `output` output folder'
|
||||||
required: false
|
required: false
|
||||||
|
default: output
|
|
@ -6,22 +6,15 @@ echo "REPO: $GITHUB_REPOSITORY"
|
||||||
echo "ACTOR: $GITHUB_ACTOR"
|
echo "ACTOR: $GITHUB_ACTOR"
|
||||||
|
|
||||||
remote_repo="https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
|
remote_repo="https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
|
||||||
remote_branch=${GH_PAGES_BRANCH:=gh-pages}
|
|
||||||
|
|
||||||
echo 'Installing Python 🐍 Requirements '
|
echo 'Installing Python 🐍 Requirements '
|
||||||
pip install -r requirements.txt
|
pip install -r requirements.txt
|
||||||
|
|
||||||
if [ -n "$PELICAN_THEME_FOLDER" ]; then
|
|
||||||
echo 'Installing Node Modules 🧰 '
|
|
||||||
pushd $PELICAN_THEME_FOLDER
|
|
||||||
npm install
|
|
||||||
popd
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo 'Building site 👷 '
|
echo 'Building site 👷 '
|
||||||
pelican ${PELICAN_CONTENT_FOLDER:=content} -o output -s ${PELICAN_CONFIG_FILE:=publishconf.py}
|
pelican ${PELICAN_CONTENT_FOLDER:=content} -o ${PELICAN_OUTPUT_FOLDER:=output} -s ${PELICAN_CONFIG_FILE:=publishconf.py}
|
||||||
|
|
||||||
echo 'Running add-ons ❌ 👉🏽 ✔ '
|
echo 'Running add-ons ➕➕ '
|
||||||
python addons.py
|
python addons.py
|
||||||
|
|
||||||
echo 'Build complete 🎉🎉 🕺💃 '
|
echo 'Build complete 🎉🎉 🕺💃 '
|
||||||
|
|
Loading…
Reference in a new issue