Skip to content

Commit

Permalink
MRG: Merge pull request #91 from octue/devops/update-ci-workflows
Browse files Browse the repository at this point in the history
Update CI/CD workflows
  • Loading branch information
cortadocodes committed Oct 6, 2021
2 parents d5d32e1 + 3b6bf8d commit 59afd80
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 18 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/python-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ on: [push]
jobs:

check-semantic-version:
if: "!contains(github.event.head_commit.message, 'skipci')"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -29,7 +30,7 @@ jobs:
run: check-semantic-version setup.py

run-tests:
if: "!contains(github.event.head_commit.message, 'skip_ci_tests')"
if: "!contains(github.event.head_commit.message, 'skipci')"
runs-on: ubuntu-latest
env:
USING_COVERAGE: '3.8'
Expand All @@ -55,7 +56,7 @@ jobs:
token: ${{ secrets.CODECOV_TOKEN }}

publish:
if: "!contains(github.event.head_commit.message, 'skip_ci_publish')"
if: "!contains(github.event.head_commit.message, 'skipci')"
runs-on: ubuntu-latest
needs: [check-semantic-version, run-tests]
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
jobs:
release:
# This job will only run if the PR has been merged (and not closed without merging).
if: "github.event.pull_request.merged == true && !contains(github.event.pull_request.head.message, 'skip_ci_release')"
if: "github.event.pull_request.merged == true && !contains(github.event.pull_request.head.message, 'skipci')"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/update-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ on:

jobs:
description:
if: "!contains(github.event.head_commit.message, 'skip_ci_update_description')"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -26,7 +25,7 @@ jobs:
- name: Compile new pull request description
run: |
echo 'PULL_REQUEST_NOTES<<EOF' >> $GITHUB_ENV
echo "$(compile-release-notes LAST_RELEASE ${{ github.event.pull_request.url }} ${{ secrets.GITHUB_TOKEN }})" >> $GITHUB_ENV
echo "$(compile-release-notes PULL_REQUEST_START --pull-request-url=${{ github.event.pull_request.url }} --api-token=${{ secrets.GITHUB_TOKEN }})" >> $GITHUB_ENV
echo EOF >> $GITHUB_ENV
- name: Update pull request body
uses: riskledger/update-pr-description@v2
Expand Down
22 changes: 10 additions & 12 deletions mkver.conf
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defaults {
preReleaseFormat: "RC{PreReleaseNumber}"
buildMetaDataFormat: "{Branch}.{ShortHash}"
includeBuildMetaData: false
whenNoValidCommitMessages: NoIncrement
whenNoValidCommitMessages: IncrementPatch
patches: [setup.py]
}

Expand All @@ -23,21 +23,19 @@ patches: [
]

commitMessageActions: [
# Disable major version increments while package is still in beta (i.e. keep the version below 1.0.0).
# {
# pattern: "BREAKING CHANGE|BREAKING-CHANGE"
# action: IncrementMajor
# }

# All new features require a minor version increase.
# Disable major version increments while package is still in beta (i.e. keep the version below 1.0.0).
{
pattern: "FEA:"
pattern: "BREAKING CHANGE"
action: IncrementMinor
}
{
pattern: "BREAKING-CHANGE"
action: IncrementMinor
}

# Any other changes, including bug fixes, require a patch version increase.
# All new features require a minor version increase.
{
pattern: ".*"
action: IncrementPatch
pattern: "FEA:"
action: IncrementMinor
}
]
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

setup(
name="twined",
version="0.0.25",
version="0.0.26",
py_modules=[],
install_requires=["jsonschema ~= 3.2.0", "python-dotenv"],
url="https://www.github.com/octue/twined",
Expand Down

0 comments on commit 59afd80

Please sign in to comment.