Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 66 additions & 0 deletions .github/workflows/chore.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Chore & Docs Workflow

on:
pull_request:
types:
- closed
branches:
- main

jobs:
merge-to-develop:
name: Merge to develop
if: >
(startsWith(github.event.pull_request.head.ref, 'chore/') ||
startsWith(github.event.pull_request.head.ref, 'docs/'))
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Merge Source Branch into Develop
run: |
git config --global user.name "bot"
git config --global user.email "bot@colorifix.com"
git fetch origin develop
git checkout develop
git merge --no-ff origin/${{ github.event.pull_request.head.ref }} -m "Merge ${{ github.event.pull_request.head.ref }} into develop"
git push origin develop

- name: Build docs
if: startsWith(github.event.pull_request.head.ref, 'docs/')
run: foo

publish-docs:
name: Publish Documentation
runs-on: ubuntu-latest
if: startsWith(github.event.pull_request.head.ref, 'docs/')

steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Install Poetry
uses: abatilo/actions-poetry@v2
with:
poetry-version: 'latest'

- name: Install dev dependencies
run: poetry install --only dev --no-root

- name: Build docs
run: poetry run mkdocs build

- name: Upload docs as artifacts
uses: actions/upload-pages-artifact@v3
with:
path: site

- name: Deploy pages
uses: actions/deploy-pages@v4
5 changes: 4 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ on:
jobs:
release_workflow:
runs-on: ubuntu-latest

if: >
(github.event_name == 'workflow_dispatch') ||
(github.event.pull_request.merged == true &&
startsWith(github.event.pull_request.head.ref, 'release/'))
steps:
- name: Gitflow action
id: gitflow-action
Expand Down
Loading