From d8ec9650d8e7a851aceec0097cf7dee709d66a2e Mon Sep 17 00:00:00 2001 From: Anne Schuth Date: Fri, 16 Feb 2024 19:57:17 +0100 Subject: [PATCH] Update ci.yml --- .github/workflows/ci.yml | 29 +++++++++++++++++++++++++++++ .github/workflows/main.yml | 19 ------------------- 2 files changed, 29 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..30e00547 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,29 @@ +name: ci +on: + push: + branches: + - master + - main +permissions: + contents: write +jobs: + deploy: + 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 + with: + python-version: 3.x + - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV + - uses: actions/cache@v4 + with: + key: mkdocs-material-${{ env.cache_id }} + path: .cache + restore-keys: | + mkdocs-material- + - run: pip install -r requirements.txt + - run: mkdocs gh-deploy --force diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index ff3087cf..00000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: Publish mkdocs via GitHub Pages -on: - push: - branches: - - main - -jobs: - build: - name: pages-build-deployment - runs-on: ubuntu-latest - steps: - - name: Checkout main - uses: actions/checkout@v4 - - - name: Deploy MkDocs - uses: mhausenblas/mkdocs-deploy-gh-pages@1.26 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - REQUIREMENTS: requirements.txt