diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3f48fce..67e5838 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,28 +1,38 @@ -name: ci +name: Build and Deploy MkDocs Site + on: push: branches: - main -permissions: - contents: write + jobs: - deploy: + build-and-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 + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 with: - python-version: 3.x - - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV - - uses: actions/cache@v4 + python-version: '3.x' + + - name: Install dependencies + run: | + pip install mkdocs + pip install mkdocs-material + pip install pymdown-extensions + pip install mkdocs-minify-plugin + pip install neoteroi-mkdocs + pip install mkdocs-git-revision-date-localized-plugin + + - name: Build MkDocs site + run: mkdocs build + + - name: Deploy GitHub Pages + uses: JamesIves/github-pages-deploy-action@releases/v3 with: - key: mkdocs-material-${{ env.cache_id }} - path: .cache - restore-keys: | - mkdocs-material- - - run: pip install mkdocs-material - - run: mkdocs gh-deploy --force \ No newline at end of file + BRANCH: gh-pages + FOLDER: site + SINGLE_COMMIT: true diff --git a/mkdocs.yml b/mkdocs.yml index 20470fc..fd19ffe 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -80,11 +80,6 @@ markdown_extensions: - pymdownx.snippets - pymdownx.superfences - neoteroi.cards - - termynal: - title: bash - buttons: macos - prompt_literal_start: - - "$" - footnotes - attr_list - md_in_html @@ -96,11 +91,6 @@ plugins: - git-revision-date-localized: type: timeago fallback_to_build_date: true - - termynal: - title: bash - buttons: macos - prompt_literal_start: - - "$" extra_css: - 'assets/css/app.css'