chore: update announcement #282
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Website Deploy | |
# Runs on pushed to the default branch but can also be | |
# run manually from the GitHub Actions page. | |
on: | |
push: | |
branches: [main] | |
workflow_dispatch: | |
# Sets permissions of the `GITHUB_TOKEN` to allow deployment to GitHub Pages | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
# Allow only one concurrent deployment, skipping runs queued between the run | |
# in-progress and latest queued. However, do NOT cancel in-progress runs as | |
# we want to allow these production deployments to complete. | |
concurrency: | |
group: "pages" | |
cancel-in-progress: false | |
jobs: | |
#========================================================================== | |
# Build the Hipcheck site with Zola and the Tailwindcss CLI | |
#-------------------------------------------------------------------------- | |
website-build: | |
runs-on: ubuntu-latest | |
env: | |
TAILWIND_VERSION: 3.4.4 | |
steps: | |
# Check out the Hipcheck repository. | |
- name: Checkout Hipcheck Repository | |
uses: actions/checkout@v4 | |
# Install the latest version of Zola. | |
- name: Install Zola | |
uses: taiki-e/install-action@v2 | |
with: | |
tool: [email protected] | |
# Install the latest version of the Tailwind CLI. | |
- name: Install Tailwind CLI | |
run: | | |
curl --proto '=https' --tlsv1.2 -sSLO https://github.com/tailwindlabs/tailwindcss/releases/download/v${TAILWIND_VERSION}/tailwindcss-linux-x64 | |
chmod +x tailwindcss-linux-x64 | |
mv tailwindcss-linux-x64 tailwindcss | |
mkdir -p "${HOME}/.local/bin" | |
mv tailwindcss "${HOME}/.local/bin/tailwindcss" | |
echo "${HOME}/.local/bin" >> $GITHUB_PATH | |
# Install the latest major version of Deno. | |
- name: Install Deno | |
uses: denoland/setup-deno@v2 | |
with: | |
deno-version: v2.x | |
# Setup GitHub Pages | |
# | |
# Specifically, this sets some variables we can use in later steps that | |
# make life easier, namely: | |
# | |
# - `base_url`: The full base URL of the site, to which paths append. | |
# - `origin`: Just the protocol and domain portion of the `base_url`. | |
# - `host`: Just the domain portion of the `base_url`. | |
# - `base_path`: Just the path portion of the `base_url`. | |
- name: Setup GitHub Pages | |
id: pages | |
uses: actions/configure-pages@v5 | |
# Build the actual site with Zola and Tailwind. | |
- name: Build Hipcheck Website | |
run: | | |
cd site | |
zola build | |
tailwindcss -i styles/main.css -o public/main.css | |
cd scripts | |
deno task bundle | |
# Upload the output of the build as an Actions artifact so the deploy | |
# step can pick it up and use it. | |
- name: Upload Build Output | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: ./site/public | |
#========================================================================== | |
# Deploy the site to GitHub Pages | |
#-------------------------------------------------------------------------- | |
website-deploy: | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-latest | |
needs: website-build | |
steps: | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 |