diff options
| author | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2024-10-13 19:27:15 +0200 |
|---|---|---|
| committer | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2024-10-13 19:27:15 +0200 |
| commit | 72e6de8bc6cd0599f2b89fe937ab6aa88bb8458a (patch) | |
| tree | 828c9fb1f2d5359a5a3b3c9ccfb0880be2345693 | |
| parent | f08b7300db6b5fd7a8708d202a53157635bf4e50 (diff) | |
Update actions
| -rw-r--r-- | .github/workflows/ci.yml | 53 | ||||
| -rw-r--r-- | .gitignore | 1 |
2 files changed, 38 insertions, 16 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 91cb81d..b6b173f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,29 +1,50 @@ -name: ci +name: Deploy to GH Pages + on: push: branches: - master - main + permissions: - contents: write + contents: read + pages: write + id-token: write + +concurrency: + group: "pages" + cancel-in-progress: false + jobs: - deploy: + build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Configure Git Credentials - run: | - git config user.name github-actions[bot] - git config user.email 41898282+github-actions[bot]@users.noreply.github.com - - uses: actions/setup-python@v5 + - uses: actions/setup-python@v5.2.0 with: - python-version: 3.x - - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV - - uses: actions/cache@v4 + python-version: 3.12 + - uses: actions/cache@v4.1.1 with: - key: mkdocs-material-${{ env.cache_id }} - path: .cache + path: ~/.cache/pip + key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} restore-keys: | - mkdocs-material- - - run: pip install mkdocs-material - - run: mkdocs gh-deploy --force + ${{ runner.os }}-pip- + - name: Install python dependencies + run: pip install -r requirements.txt + - name: Build the site + run: mkdocs build + - name: Upload static to GH Pages + uses: actions/upload-pages-artifact@v3.0.1 + with: + path: site/ + + deploy: + environment: + name: github-pages + url: ${{ steps.upload-artifact.outputs.url }} + runs-on: ubuntu-latest + needs: build + steps: + - name: Deploy to github pages + id: deployment + uses: actions/deploy-pages@v4
\ No newline at end of file @@ -1 +1,2 @@ venv/ +site/
\ No newline at end of file |
