-
Notifications
You must be signed in to change notification settings - Fork 12
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
add version.txt and github workflow to update file. #208
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
cd64e76
add version.txt and pre-push hook
jedwards4b 757fed1
update version.txt
jedwards4b ba00e50
Merge branch 'main' into add_version_file
jedwards4b 3d13177
update version.txt
jedwards4b cb06623
use github workflow to update version.txt
jedwards4b 1506bbf
Need to update file before creating version
jedwards4b 46b2eb9
improve workflow name
jedwards4b 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 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 |
---|---|---|
@@ -1,16 +1,43 @@ | ||
name: Bump version | ||
name: Update file on PR merge | ||
on: | ||
push: | ||
pull_request: | ||
branches: | ||
- main | ||
types: closed | ||
|
||
jobs: | ||
build: | ||
update_version: | ||
if: github.event.pull_request.merged == true | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
# Fetch full depth, otherwise the last step overwrites the last commit's parent, essentially removing the graph. | ||
fetch-depth: 0 | ||
|
||
- name: GenerateTag | ||
id: name_tag | ||
uses: mathieudutour/[email protected] | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
create_annotated_tag: true | ||
default_bump: patch | ||
dry_run: true | ||
tag_prefix: manic- | ||
- name: Update version.txt | ||
run: | | ||
echo "${{ steps.name_tag.outputs.new_tag }}" > version.txt | ||
- name: Amend the last commit | ||
run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "OpenRCT2 git bot" | ||
git commit -a --amend --no-edit | ||
git push --force-with-lease | ||
echo "Complete"name: Bump version | ||
- name: Bump version and push tag | ||
id: tag_version | ||
uses: mathieudutour/github-tag-action@v5.5 | ||
id: really_tag_version | ||
uses: mathieudutour/github-tag-action@v6.1 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
create_annotated_tag: true | ||
|
This file contains 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 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 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 @@ | ||
manic-1.2.24-3-gba00e50 | ||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this going to get cleaned up when it is tagged?
I.s., will it be
manic-1.2.25
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes it will be manic-1.2.25.