Skip to content

Merge pull request #741 from rust-lang/update-wgs-status-2 #56

Merge pull request #741 from rust-lang/update-wgs-status-2

Merge pull request #741 from rust-lang/update-wgs-status-2 #56

Workflow file for this run

name: Deploy
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository code
uses: actions/checkout@v2
with:
submodules: true
- name: Install Hugo
run: sudo apt install hugo
- name: Minify HTML
run: hugo --minify
- name: Deploy
run: |
deploy_dir=public
# Ensure GitHub doesn't mess around with the uploaded file.
# Without the file, for example, files with an underscore in the name won't be
# included in the pages.
touch "${deploy_dir}/.nojekyll"
# Push the website to GitHub pages
cd "${deploy_dir}"
rm -rf .git
git init
git config user.name "Deploy from CI"
git config user.email ""
git add .
git commit -m "Deploy ${GITHUB_SHA} to gh-pages"
git push -f "https://x-token:${github_token}@github.com/${GITHUB_REPOSITORY}" master:gh-pages
env:
github_token: ${{ secrets.GITHUB_TOKEN }}