Skip to content

Commit

Permalink
Merge pull request #64 from MinBZK/feature/add-ci-tools
Browse files Browse the repository at this point in the history
Feature/add ci tools
  • Loading branch information
ruthkoole authored Mar 21, 2024
2 parents c8d0d3a + 0f548af commit bbc26bc
Show file tree
Hide file tree
Showing 4 changed files with 87 additions and 10 deletions.
31 changes: 31 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "friday"
time: "10:00"
timezone: "Europe/Amsterdam"
open-pull-requests-limit: 5
reviewers:
- "ruthkoole"
groups:
all-github-actions:
patterns:
- "*"

- package-ecosystem: "pip"
directory: "/"
schedule:
interval: "weekly"
day: "friday"
time: "10:00"
timezone: "Europe/Amsterdam"
open-pull-requests-limit: 5
reviewers:
- "ruthkoole"
groups:
all-pip-packages:
patterns:
- "*"
20 changes: 11 additions & 9 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,17 @@ on:
- main

jobs:
build:
name: pages-build-deployment
deploy:
name: deploy main
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v4
- uses: actions/checkout@v4

- name: Deploy MkDocs
uses: mhausenblas/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REQUIREMENTS: requirements.txt
- uses: actions/setup-python@v5
with:
python-version: 3.x
cache: 'pip'

- run: pip install -r requirements.txt

- run: mkdocs gh-deploy --force
43 changes: 43 additions & 0 deletions .github/workflows/preview.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Deploy PR previews

on:
pull_request:
types:
- opened
- reopened
- synchronize
- closed

concurrency: preview-${{ github.ref }}

jobs:
deploy:
name: deploy PR
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
if: github.event.action != 'closed'
with:
python-version: 3.x
cache: 'pip'

- name: install dependencies
if: github.event.action != 'closed'
run: pip install -r requirements.txt

- name: build preview
if: github.event.action != 'closed'
run: mkdocs build

- uses: actions/upload-artifact@v4
if: github.event.action != 'closed'
with:
name: AlgoritmeKaderWebsite-${{github.event.number}}
path: ./site/

- name: Deploy preview
uses: rossjrw/pr-preview-action@v1
with:
source-dir: ./site/
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# build files
site
site
.venv/

0 comments on commit bbc26bc

Please sign in to comment.