fix: unify mobile lang toggle and right-align ossheroes mobile nav #139
This file contains hidden or 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: Deploy to github pages | |
| on: | |
| push: | |
| branches: | |
| - main | |
| workflow_run: | |
| workflows: ["Monthly Script Runner"] | |
| types: | |
| - completed | |
| jobs: | |
| build-deploy: | |
| permissions: | |
| contents: write | |
| runs-on: ubuntu-latest | |
| if: "!contains(github.event.head_commit.message, 'skip ci')" | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # required so the deploy action can push | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| cache-dependency-path: pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Build www site | |
| run: pnpm --filter www build | |
| - name: Build ossheroes site | |
| run: pnpm --filter ossheroes build | |
| - name: Verify ossheroes URLs and SEO | |
| run: | | |
| pnpm --filter ossheroes verify:urls | |
| pnpm --filter ossheroes verify:seo | |
| - name: Merge outputs for GitHub Pages | |
| run: | | |
| rm -rf dist | |
| cp -r apps/www/dist/. dist/ | |
| cp -r apps/ossheroes/dist/. dist/ | |
| # sanity checks | |
| for f in index.html sitemap.xml robots.txt llms.txt; do | |
| if [ ! -f "dist/${f}" ]; then | |
| echo "Error: dist/${f} not found" | |
| exit 1 | |
| fi | |
| done | |
| for f in heroes/index.html ossheroes/index.html; do | |
| if [ ! -f "dist/${f}" ]; then | |
| echo "Error: dist/${f} not found" | |
| exit 1 | |
| fi | |
| done | |
| if ! find dist/hero -mindepth 2 -maxdepth 2 -name index.html -print -quit | grep -q .; then | |
| echo "Error: no developer profile was built under dist/hero" | |
| exit 1 | |
| fi | |
| - name: Deploy 🚀 | |
| uses: JamesIves/github-pages-deploy-action@v4 | |
| with: | |
| branch: gh-pages | |
| folder: dist |