-
Notifications
You must be signed in to change notification settings - Fork 0
Develop #53
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
Develop #53
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
5fbca45
Add Clear method and correct documentation.
bfarmer67 4dde247
updated workflows to use the new system.
varndellwagglebee aa169c4
updated build props to include license
varndellwagglebee d0fe2b7
Update Directory.Build.props
varndellwagglebee fb0ffb2
updated build props to include license
varndellwagglebee 36f812e
update README with image and build-status badge
varndellwagglebee 2a9b653
Merge branch 'main' into develop
varndellwagglebee 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 |
|---|---|---|
| @@ -1,46 +1,52 @@ | ||
| name: Format | ||
|
|
||
| on: | ||
| on: | ||
| push: | ||
| workflow_run: | ||
| workflows: | ||
| - Create Prerelease | ||
| - Create Release | ||
| types: [requested] | ||
| workflow_dispatch: | ||
| pull_request: | ||
| types: [opened,edited,synchronize,reopened] | ||
| branches: | ||
| - main | ||
| - develop | ||
| types: [opened, edited, synchronize, reopened] | ||
| branches: [main, develop] | ||
|
|
||
| workflow_run: | ||
| workflows: [Create Prerelease, Create Release] | ||
| types: [requested] | ||
|
|
||
| permissions: | ||
| contents: write | ||
|
|
||
| env: | ||
| DOTNET_VERSION: "9.0.x" | ||
| contents: write | ||
| pull-requests: write | ||
| actions: read | ||
|
|
||
| jobs: | ||
| format: | ||
| discover: | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| branch_name: ${{ steps.set_branch.outputs.branch_name }} | ||
|
|
||
| steps: | ||
| - name: Checkout Code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Setup .NET | ||
| uses: actions/setup-dotnet@v4 | ||
| with: | ||
| dotnet-version: ${{ env.DOTNET_VERSION }} | ||
|
|
||
| - name: Format | ||
| run: dotnet format | ||
|
|
||
| - name: Update Styles | ||
| continue-on-error: true | ||
| run: | | ||
| git config --global user.name 'github-actions' | ||
| git config --global user.email '[email protected]' | ||
| git commit -am "Updated code formatting to match rules in .editorconfig" | ||
| git push | ||
| - id: set_branch | ||
| shell: bash | ||
| run: | | ||
| # 1. Pick the raw branch/ref for each trigger type | ||
| if [[ "${{ github.event_name }}" == "workflow_run" ]]; then | ||
| RAW='${{ github.event.workflow_run.head_branch }}' | ||
| elif [[ "${{ github.event_name }}" == "pull_request" ]]; then | ||
| RAW='${{ github.event.pull_request.base.ref }}' | ||
| else | ||
| RAW='${{ github.ref }}' | ||
| fi | ||
| # 2. Strip the refs/heads/ prefix if present | ||
| CLEAN="${RAW#refs/heads/}" | ||
| echo "Detected branch: $CLEAN" | ||
| echo "branch_name=$CLEAN" >> "$GITHUB_OUTPUT" | ||
| format: | ||
| needs: discover | ||
| if: ${{ needs.discover.result == 'success' }} | ||
| uses: Stillpoint-Software/shared-workflows/.github/workflows/format.yml@main | ||
| with: | ||
| dotnet_version: "9.0.x" | ||
| branch: ${{ needs.discover.outputs.branch_name }} | ||
| secrets: inherit | ||
|
|
||
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,74 @@ | ||
| name: Create Release | ||
|
|
||
| on: | ||
| workflow_dispatch: | ||
| inputs: | ||
| mode: | ||
| description: | | ||
| How to set the version: | ||
| - explicit: set to a specific value (e.g., 1.3-alpha) | ||
| - bump: bump major/minor/patch from current SimpleVersion and apply optional prerelease | ||
| - auto: policy-based (develop->next minor -alpha; hotfix/*->next patch -alpha; main/vX.Y->stable) | ||
| type: choice | ||
| options: [auto, bump, explicit] | ||
| default: auto | ||
| version: | ||
| description: "When mode=explicit: exact version (e.g., 1.3-alpha, 1.2.3, 1.4.0-rc)" | ||
| type: string | ||
| default: "" | ||
| increment: | ||
| description: "When mode=bump: major | minor | patch" | ||
| type: choice | ||
| options: [major, minor, patch] | ||
| default: patch | ||
| prerelease: | ||
| description: "When mode=bump: prerelease suffix WITHOUT leading dash (e.g., alpha, beta, rc). Leave blank for stable." | ||
| type: string | ||
| default: "" | ||
|
|
||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| packages: write | ||
|
|
||
| run-name: "Create Release · ${{ inputs.mode }} · ${{ github.ref_name }}" | ||
|
|
||
| jobs: | ||
| validate-inputs: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Check conditional requirements | ||
| run: | | ||
| set -euo pipefail | ||
| MODE='${{ inputs.mode }}' | ||
| VERSION='${{ inputs.version }}' | ||
| INCR='${{ inputs.increment }}' | ||
| if [[ "$MODE" == "explicit" && -z "$VERSION" ]]; then | ||
| echo "❌ mode=explicit requires 'version' (e.g., 1.3-alpha)."; exit 1 | ||
| fi | ||
| if [[ "$MODE" == "bump" && -z "$INCR" ]]; then | ||
| echo "❌ mode=bump requires 'increment' (major|minor|patch)."; exit 1 | ||
| fi | ||
| echo "✅ inputs look good." | ||
|
|
||
| set-version: | ||
| needs: validate-inputs | ||
| uses: Stillpoint-Software/shared-workflows/.github/workflows/set_version.yml@main | ||
| with: | ||
| target_branch: ${{ github.ref_name }} | ||
| mode: ${{ inputs.mode }} | ||
| version: ${{ inputs.version }} | ||
| increment: ${{ inputs.increment }} | ||
| prerelease: ${{ inputs.prerelease }} | ||
| secrets: inherit | ||
|
|
||
| create-release: | ||
| needs: set-version | ||
| uses: Stillpoint-Software/shared-workflows/.github/workflows/prepare_release.yml@main | ||
| with: | ||
| target_branch: ${{ github.ref_name }} | ||
| tag: ${{ needs.set-version.outputs.tag }} | ||
| prerelease: ${{ needs.set-version.outputs.new_prerelease }} | ||
| draft: true | ||
| secrets: | ||
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
Oops, something went wrong.
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.