-
Notifications
You must be signed in to change notification settings - Fork 1
GitHub workflows and changelog #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
36d0c8a
renamed lint workflow
ghbm-itk cda3f12
Added changelog check workflow
ghbm-itk 89134cf
Added version check workflow
ghbm-itk ed01846
Added changelog
ghbm-itk 93b6cd5
Added version number to ui
ghbm-itk 68dba6d
Fixed changelog
ghbm-itk 5901b65
Fixed changelog
ghbm-itk b614c99
Fixed version
ghbm-itk 645d6a6
Limited workflows to main
ghbm-itk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| name: Check Changelog | ||
|
|
||
| on: pull_request | ||
|
|
||
| jobs: | ||
| changelog: | ||
| runs-on: ubuntu-latest | ||
| name: Changelog should be updated | ||
| strategy: | ||
| fail-fast: false | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
| with: | ||
| fetch-depth: 2 | ||
|
|
||
| - name: Git fetch | ||
| run: git fetch | ||
|
|
||
| - name: Check that changelog has been updated. | ||
| run: git diff --exit-code origin/${{ github.base_ref }} -- CHANGELOG.md && exit 1 || exit 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| name: Check pyproject.toml Version Change | ||
|
|
||
| on: | ||
| pull_request: | ||
| branches: | ||
| - 'main' | ||
|
|
||
| jobs: | ||
| check-version: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Get current version in PR branch | ||
| id: get-pr-version | ||
| run: | | ||
| PR_VERSION=$(sed -n -e 's/^version = "\(.*\)"/\1/p' pyproject.toml) | ||
| echo "PR_VERSION=$PR_VERSION" >> $GITHUB_ENV | ||
|
|
||
| - name: Get version in base branch | ||
| id: get-base-version | ||
| run: | | ||
| git fetch origin ${{ github.event.pull_request.base.ref }} | ||
| git checkout FETCH_HEAD | ||
| BASE_VERSION=$(sed -n -e 's/^version = "\(.*\)"/\1/p' pyproject.toml) | ||
| echo "BASE_VERSION=$BASE_VERSION" >> $GITHUB_ENV | ||
|
|
||
| - name: Compare versions | ||
| run: | | ||
| echo "PR version: ${{ env.PR_VERSION }}" | ||
| echo "Base branch version: ${{ env.BASE_VERSION }}" | ||
|
|
||
| if [ "${{ env.PR_VERSION }}" == "${{ env.BASE_VERSION }}" ]; then | ||
| echo "Version number has not been changed." | ||
| exit 1 | ||
| else | ||
| echo "Version number has changed." | ||
| fi | ||
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| # Changelog | ||
|
|
||
| All notable changes to this project will be documented in this file. | ||
|
|
||
| The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
| and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
|
|
||
| ## [Unreleased] | ||
|
|
||
| ### Added | ||
|
|
||
| - Changelog! | ||
| - PR workflows. | ||
| - Version number in UI. | ||
|
|
||
| ## [0.0.1] | ||
|
|
||
| - Initial release | ||
|
|
||
| [Unreleased]: https://github.com/itk-dev-rpa/OpenPostbud/compare/0.0.1...HEAD | ||
| [0.0.1]: https://github.com/itk-dev-rpa/OpenPostbud/releases/tag/0.0.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.