-
-
Notifications
You must be signed in to change notification settings - Fork 891
enable using github actions for build #1061
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
58 commits
Select commit
Hold shift + click to select a range
3d1d7f8
enable using github actions for building
tocsoft 6e2ba68
stop appveyor publishing pacakges
tocsoft 6a234af
Merge branch 'master' into sw/github-actions
tocsoft af7077a
Merge branch 'master' into sw/github-actions
JimBobSquarePants 991d6cb
Merge remote-tracking branch 'remotes/origin/master' into sw/github-a…
tocsoft a1df496
Merge branch 'sw/github-actions' of https://github.com/SixLabors/Imag…
JimBobSquarePants cb0597a
Merge branch 'master' into sw/github-actions
JimBobSquarePants b12dd69
Use dotnet test
JimBobSquarePants 9fdc4ea
Update build-and-test.yml
JimBobSquarePants a1d2e6f
Remove old xunit reference
JimBobSquarePants fc6ac75
Debug framework skipping
JimBobSquarePants df66a98
Skip linux for testing
JimBobSquarePants 60ab03b
Update build-and-test.yml
JimBobSquarePants 92e5d5c
Use pwsh for scripts
JimBobSquarePants 44733d3
Fix options naming
JimBobSquarePants 69f3d18
Fix booleans?
JimBobSquarePants 3337d2d
Conditionals are hard.
JimBobSquarePants 3755f88
Update build-and-test.yml
JimBobSquarePants c7fdf1a
Fix missing quote
JimBobSquarePants e2f090a
Update build-and-test.yml
JimBobSquarePants abde989
Fix tests
JimBobSquarePants f7e62ad
Combine xunit and test for converage
JimBobSquarePants 22661f0
dotnet restore is implicit in core sdk 2+
JimBobSquarePants f2162a7
Update build.ps1
JimBobSquarePants 30dc32a
Try passing variable as bool
JimBobSquarePants 932673d
Update test.ps1
JimBobSquarePants b343092
Use strings
JimBobSquarePants d8610f4
Update test.ps1
JimBobSquarePants fa05119
Update PngEncoderTests.cs
JimBobSquarePants 194e9ab
Fix codecov condition
JimBobSquarePants 15244d3
Use targets. Coverage should now upload
JimBobSquarePants 2bf586a
Enable ubuntu
JimBobSquarePants 3f8fa7c
Add targeting pack for linux
JimBobSquarePants 3c6bad3
Use dotnet test on linux
JimBobSquarePants 6dad4b5
GitVersion experiment
JimBobSquarePants b3a71a7
Update build-and-test.yml
JimBobSquarePants 76f27dd
Delete gitversion.yml
JimBobSquarePants 6a40693
Create GitVersion.yml
JimBobSquarePants afbc1cb
Cleanup
JimBobSquarePants c6f282c
Update ci-build.ps1
JimBobSquarePants a9576ef
Cleanup solution
JimBobSquarePants 9dc422d
Add new target frameworks
JimBobSquarePants c957caa
Add netcore 3.1 SDK action
JimBobSquarePants ec847de
Revert "Add netcore 3.1 SDK action"
JimBobSquarePants ce124ac
Add 3.1.101 SDK
JimBobSquarePants d7338e8
Update Directory.Build.props
JimBobSquarePants 99434bf
Test xunit pipeline
JimBobSquarePants 5021507
Move nuget fix
JimBobSquarePants 0e0ed60
Enable linux
JimBobSquarePants c41a4c4
Try using bash
JimBobSquarePants a639460
Test all frameworks
JimBobSquarePants a8425dd
Only use the xunit runner when we really have to.
JimBobSquarePants 5f06fb9
Restore CI variable and skip troublesome tests
JimBobSquarePants 45bc1bc
Delete bak file and undo bad gitignore changes
JimBobSquarePants 21ad572
Speed up coverage and respond to comments
JimBobSquarePants 1d4887f
Update ci-test.ps1
JimBobSquarePants 3a64f92
Fix netstandard 1.3 build
JimBobSquarePants 2e8f50d
Temporarily disable Stylecop in tests
JimBobSquarePants 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,105 @@ | ||
| name: Build | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - master | ||
| tags: | ||
| - "v*" | ||
| pull_request: | ||
| branches: | ||
| - master | ||
|
|
||
| jobs: | ||
| Build: | ||
| strategy: | ||
| matrix: | ||
| options: | ||
| - os: ubuntu-latest | ||
| framework: netcoreapp3.1 | ||
| runtime: -x64 | ||
| codecov: false | ||
| - os: windows-latest | ||
| framework: netcoreapp3.1 | ||
| runtime: -x64 | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's worth to also test x86 + 3.1 because of the floating point magic we do. |
||
| codecov: true | ||
| - os: windows-latest | ||
| framework: netcoreapp2.1 | ||
| runtime: -x64 | ||
| codecov: false | ||
| - os: windows-latest | ||
| framework: net472 | ||
| runtime: -x64 | ||
| codecov: false | ||
| - os: windows-latest | ||
| framework: net472 | ||
| runtime: -x86 | ||
| codecov: false | ||
|
|
||
| runs-on: ${{matrix.options.os}} | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v2 | ||
|
|
||
| - name: Install NuGet | ||
| uses: NuGet/setup-nuget@v1 | ||
|
|
||
| - name: Setup Git | ||
| shell: bash | ||
| run: | | ||
| git config --global core.autocrlf false | ||
| git config --global core.longpaths true | ||
| git fetch --prune --unshallow | ||
| git submodule -q update --init --recursive | ||
| - name: Fetch Tags for GitVersion | ||
| run: | | ||
| git fetch --tags | ||
| - name: Fetch master for GitVersion | ||
| if: github.ref != 'refs/heads/master' | ||
| run: git branch --create-reflog master origin/master | ||
|
|
||
| - name: Install GitVersion | ||
| uses: gittools/actions/[email protected] | ||
| with: | ||
| versionSpec: "5.1.x" | ||
|
|
||
| - name: Use GitVersion | ||
| id: gitversion # step id used as reference for output values | ||
| uses: gittools/actions/[email protected] | ||
|
|
||
| - name: Setup DotNet SDK | ||
| uses: actions/setup-dotnet@v1 | ||
| with: | ||
| dotnet-version: "3.1.101" | ||
|
|
||
| - name: Build | ||
| shell: pwsh | ||
| run: ./ci-build.ps1 "${{steps.gitversion.outputs.nuGetVersion}}" "${{matrix.options.framework}}" | ||
|
|
||
| - name: Test | ||
| shell: pwsh | ||
| run: ./ci-test.ps1 "${{matrix.options.os}}" "${{matrix.options.framework}}" "${{matrix.options.runtime}}" "${{matrix.options.codecov}}" | ||
| env: | ||
| CI : True | ||
| XUNIT_PATH: .\tests\ImageSharp.Tests # Required for xunit | ||
|
|
||
| - name: Update Codecov | ||
| uses: iansu/[email protected] | ||
| if: matrix.options.codecov == true | ||
| with: | ||
| token: ${{secrets.CODECOV_TOKEN}} | ||
| file: "coverage.${{matrix.options.framework}}.xml" | ||
| flags: unittests | ||
|
|
||
| - name: Pack # We can use this filter as we know it happens only once and takes the most time to complete. | ||
| if: (github.event_name == 'push') && (matrix.options.codecov == true) | ||
| shell: pwsh | ||
| run: ./ci-build.ps1 "${{steps.gitversion.outputs.nuGetVersion}}" | ||
|
|
||
| - name: Publish to MyGet | ||
| if: (github.event_name == 'push') && (matrix.options.codecov == true) | ||
| shell: pwsh | ||
| run: nuget.exe push .\artifacts\*.nupkg ${{secrets.MYGET_TOKEN}} -Source https://www.myget.org/F/sixlabors/api/v2/package | ||
| # TODO: If github.ref starts with 'refs/tags' then it was tag push and we can optionally push out package to nuget.org | ||
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 was deleted.
Oops, something went wrong.
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
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.