-
Notifications
You must be signed in to change notification settings - Fork 0
Develop #2
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
Develop #2
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
2955cd7
wip
ptr727 3174265
wip
ptr727 ef5b5b8
wip
ptr727 9f3440b
wip
ptr727 637ce5e
wip
ptr727 d1229f0
wip
ptr727 dead8dd
wip
ptr727 bb92a34
chmod +x
ptr727 730bfde
wip
ptr727 2b15ea1
Single PR
ptr727 bbb0442
signed?
ptr727 67fb26f
wip
ptr727 64e7b12
wip
ptr727 6ec4a1b
Update README.md
ptr727 9ca68a1
Update .github/workflows/build-docker-task.yml
ptr727 c1e7aa1
Update ProjectTemplate.slnx
ptr727 9d1e1a9
Update .github/workflows/build-project-task.yml
ptr727 663ddee
Update .github/workflows/build-library-task.yml
ptr727 70022fa
Update .github/workflows/build-executable-task.yml
ptr727 f3ebba5
Refactor build-docker-task.yml workflow configuration
ptr727 76badda
wip
ptr727 bdc7438
wip
ptr727 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
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,83 @@ | ||
| name: Build executable task | ||
|
|
||
| env: | ||
| IS_MAIN_BRANCH: ${{ endsWith(github.ref, 'refs/heads/main') }} | ||
| PROJECT_FILE: ./Console/Console.csproj | ||
| PROJECT_ARTIFACT: Console.7z | ||
|
|
||
| on: | ||
| workflow_call: | ||
| outputs: | ||
| artifact-id: | ||
| value: ${{ jobs.upload-build-artifacts.outputs.artifact-id }} | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
|
|
||
| get-version: | ||
| name: Get version information | ||
| uses: ./.github/workflows/get-version-task.yml | ||
| secrets: inherit | ||
|
|
||
| build-executable-matrix: | ||
| name: Build executable project matrix | ||
| runs-on: ubuntu-latest | ||
| needs: [get-version] | ||
| strategy: | ||
| matrix: | ||
| runtime: [ win-x64, linux-x64, linux-musl-x64, linux-arm, linux-arm64, osx-x64, osx-arm64 ] | ||
|
|
||
| steps: | ||
|
|
||
| - name: Setup .NET SDK | ||
| uses: actions/setup-dotnet@v5 | ||
| with: | ||
| dotnet-version: 10.x | ||
|
|
||
| - name: Checkout code | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: Build executable project | ||
| run: >- | ||
| dotnet publish ${{ env.PROJECT_FILE }} | ||
| --runtime ${{ matrix.runtime }} | ||
| --output ${{ runner.temp }}/publish/${{ matrix.runtime }} | ||
| --configuration ${{ env.IS_MAIN_BRANCH == 'true' && 'Release' || 'Debug' }} | ||
| -property:PublishAot=false | ||
| -property:Version=${{ needs.get-version.outputs.AssemblyVersion }} | ||
| -property:FileVersion=${{ needs.get-version.outputs.AssemblyFileVersion }} | ||
| -property:AssemblyVersion=${{ needs.get-version.outputs.AssemblyVersion }} | ||
| -property:InformationalVersion=${{ needs.get-version.outputs.AssemblyInformationalVersion }} | ||
| -property:PackageVersion=${{ needs.get-version.outputs.SemVer2 }} | ||
|
|
||
| - name: Upload matrix build artifacts | ||
| uses: actions/upload-artifact@v6 | ||
| with: | ||
| name: publish-${{ matrix.runtime }} | ||
| path: ${{ runner.temp }}/publish | ||
|
|
||
| upload-build-artifacts: | ||
| name: Upload matrix build artifacts | ||
| outputs: | ||
| artifact-id: ${{ steps.artifact-upload-step.outputs.artifact-id }} | ||
| runs-on: ubuntu-latest | ||
| needs: [ build-executable-matrix ] | ||
|
|
||
| steps: | ||
|
|
||
| - name: Download matrix build artifacts | ||
| uses: actions/download-artifact@v7 | ||
| with: | ||
| pattern: publish-* | ||
| merge-multiple: true | ||
| path: ${{ runner.temp }}/publish | ||
|
|
||
| - name: Zip build output | ||
| run: 7z a -t7z ${{ runner.temp }}/${{ env.PROJECT_ARTIFACT }} ${{ runner.temp }}/publish/* | ||
|
|
||
| - name: Upload build artifacts | ||
| id: artifact-upload-step | ||
| uses: actions/upload-artifact@v6 | ||
| with: | ||
| name: executable-build | ||
| path: ${{ runner.temp }}/${{ env.PROJECT_ARTIFACT }} | ||
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,72 @@ | ||
| name: Build library task | ||
|
|
||
| env: | ||
| IS_MAIN_BRANCH: ${{ endsWith(github.ref, 'refs/heads/main') }} | ||
| PROJECT_FILE: ./Library/Library.csproj | ||
| PROJECT_ARTIFACT: Library.7z | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| nuget: | ||
| required: false | ||
| type: boolean | ||
| default: false | ||
| outputs: | ||
| artifact-id: | ||
| value: ${{ jobs.build-library.outputs.artifact-id }} | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
|
|
||
| get-version: | ||
| name: Get version information | ||
| uses: ./.github/workflows/get-version-task.yml | ||
| secrets: inherit | ||
|
|
||
| build-library: | ||
| name: Build library project | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| artifact-id: ${{ steps.artifact-upload-step.outputs.artifact-id }} | ||
| needs: [get-version] | ||
|
|
||
| steps: | ||
|
|
||
| - name: Setup .NET SDK | ||
| uses: actions/setup-dotnet@v5 | ||
| with: | ||
| dotnet-version: 10.x | ||
|
|
||
| - name: Checkout code | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: Build library project | ||
| run: >- | ||
| dotnet build ${{ env.PROJECT_FILE }} | ||
| --output ${{ runner.temp }}/publish | ||
| --configuration ${{ env.IS_MAIN_BRANCH == 'true' && 'Release' || 'Debug' }} | ||
|
ptr727 marked this conversation as resolved.
|
||
| -property:Version=${{ needs.get-version.outputs.AssemblyVersion }} | ||
| -property:FileVersion=${{ needs.get-version.outputs.AssemblyFileVersion }} | ||
| -property:AssemblyVersion=${{ needs.get-version.outputs.AssemblyVersion }} | ||
| -property:InformationalVersion=${{ needs.get-version.outputs.AssemblyInformationalVersion }} | ||
| -property:PackageVersion=${{ needs.get-version.outputs.SemVer2 }} | ||
|
|
||
| - name: Publish to NuGet.org | ||
| if: ${{ inputs.nuget }} | ||
| run: >- | ||
| dotnet nuget push ${{ runner.temp }}/publish/*.nupkg | ||
| --source https://api.nuget.org/v3/index.json | ||
| --api-key ${{ secrets.NUGET_API_KEY }} | ||
| --skip-duplicate | ||
|
|
||
| - name: Zip output | ||
| run: | | ||
| 7z a -t7z ${{ runner.temp }}/${{ env.PROJECT_ARTIFACT }} ${{ runner.temp }}/publish/* | ||
|
|
||
| - name: Upload build artifacts | ||
| id: artifact-upload-step | ||
| uses: actions/upload-artifact@v6 | ||
| with: | ||
| name: library-build | ||
| path: ${{ runner.temp }}/${{ env.PROJECT_ARTIFACT }} | ||
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
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.