Update projects and main page #46
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: Build and deploy web to GitHub Pages | |
| on: | |
| push: | |
| branches: | |
| - master | |
| - main | |
| schedule: | |
| - cron: '0 0 1 * *' # on first day of every month | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| env: | |
| MY_GITHUB_TOKEN: ${{ secrets.MY_GITHUB_TOKEN }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| - name: Set up Python 3.x | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: 3.x | |
| - name: Cache dependencies | |
| uses: actions/cache@v3 | |
| with: | |
| key: ${{ github.ref }} | |
| path: .cache | |
| - name: Install dependencies | |
| run: make install | |
| - name: Generate web | |
| run: python3 projectIndexer.py generate --fetch-directly --compile-tailwind --hide-private --verbose --github-token ${{ secrets.MY_GITHUB_TOKEN }} | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./build |