Skip to content

Commit 95f9255

Browse files
committed
Fix and document rc version
1 parent 5e25cc5 commit 95f9255

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

.github/workflows/build-tool.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,13 @@ jobs:
7474
PRODUCTION_VERSION="$(cat VERSION)"-"${{github.ref_name}}"."${{github.run_number}}"
7575
echo "PRODUCTION_VERSION = ${PRODUCTION_VERSION}"
7676
dotnet pack --configuration Release --no-build --no-restore --output artifacts/packages -p:PackageVersion=$PRODUCTION_VERSION
77+
78+
- name: Execute dotnet pack with release candidate from pull request
79+
if: ${{ startsWith(github.head_ref, 'rc-')}}
80+
run: |
81+
PRODUCTION_VERSION="$(cat VERSION)"-"${{github.head_ref}}"."${{github.run_number}}"
82+
echo "PRODUCTION_VERSION = ${PRODUCTION_VERSION}"
83+
dotnet pack --configuration Release --no-build --no-restore --output artifacts/packages -p:PackageVersion=$PRODUCTION_VERSION
7784
7885
- name: Upload package artifacts
7986
uses: actions/upload-artifact@v4

README.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,10 @@ To add the information gathered in the workflow to be shown on the MORYX-CodeCov
4545

4646
## Contribute
4747

48-
If you have an idea to improve a template or can think of a new useful template, please make your changes based on one of the template branches and open a pull request. If you want to add a template, extend the branch list in one commit and the template definition in another. This way we can easily put your template into a separate branch. **Note:** All branches except *master* will be rebased regularly, to keep grafting them easy. To avoid losing previous merge request information, all branch merge requests are merged by rebase squashing.
48+
If you have an idea to improve a template or can think of a new useful template, please make your changes based on one of the template branches and open a pull request. If you want to add a template, extend the branch list in one commit and the template definition in another. This way we can easily put your template into a separate branch. **Note:** All branches except *master* will be rebased regularly, to keep grafting them easy. To avoid losing previous merge request information, all branch merge requests are merged by rebase squashing.
49+
50+
### Github ref variables
51+
52+
The detailted documentation is [here](https://docs.github.com/de/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs#github-context). However it was not always obvious what value was where.
53+
54+
- current branch: When building on a push to e.g. dev, the current branch is in `ref_name`. However in pull requests this refers to the pull-request id and you need `head_ref` instead

0 commit comments

Comments
 (0)