Skip to content

feat: secret posts

feat: secret posts #21

Workflow file for this run

# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: Build Blog
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
fetch-depth: 0
- uses: pnpm/action-setup@v4
with:
version: latest
- name: Setting timezone
run: sudo timedatectl set-timezone America/New_York
- name: Install software dependencies
run: sudo apt-get install -y highlight imagemagick ipe bzip2 inkscape
- name: Setting up online LaTeX compilation
run: mkdir -p ~/.ipe/latexrun; echo "https://latexonline.cc" > ~/.ipe/latexrun/url1.txt
- name: Install soupault
env:
SOUPAULT_VERSION: 4.10.0
run: |
wget https://github.com/PataphysicalSociety/soupault/releases/download/$SOUPAULT_VERSION/soupault-$SOUPAULT_VERSION-linux-x86_64.tar.gz
tar xvf soupault-$SOUPAULT_VERSION-linux-x86_64.tar.gz
sudo mv -v ./soupault-$SOUPAULT_VERSION-linux-x86_64/soupault /usr/bin/
rm -rf soupault-$SOUPAULT_VERSION-linux-x86_64.tar.gz soupault-$SOUPAULT_VERSION-linux-x86_64
- name: Install pnpm dependencies
run: pnpm i
- name: Check formatting
run: pnpm exec prettier . --check
- name: Build
run: make build
- name: Install netlify tools
run: pnpm install -g netlify-cli
- name: Deploy to Netlify
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.MY_TOKEN_SECRET }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
run: netlify deploy --dir build --site $NETLIFY_SITE_ID --auth $NETLIFY_AUTH_TOKEN --prod