-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove appveyor build add github actions build
- Loading branch information
1 parent
cc554dd
commit 5d35bfe
Showing
24 changed files
with
524 additions
and
151 deletions.
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
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,17 +1,63 @@ | ||
# Auto detect text files and perform LF normalization | ||
############################################################################### | ||
# Set default behavior to automatically normalize line endings. | ||
############################################################################### | ||
* text=auto | ||
|
||
# Custom for Visual Studio | ||
*.cs diff=csharp | ||
############################################################################### | ||
# Set default behavior for command prompt diff. | ||
# | ||
# This is need for earlier builds of msysgit that does not have it on by | ||
# default for csharp files. | ||
# Note: This is only used by command line | ||
############################################################################### | ||
#*.cs diff=csharp | ||
|
||
# Standard to msysgit | ||
*.doc diff=astextplain | ||
*.DOC diff=astextplain | ||
*.docx diff=astextplain | ||
*.DOCX diff=astextplain | ||
*.dot diff=astextplain | ||
*.DOT diff=astextplain | ||
*.pdf diff=astextplain | ||
*.PDF diff=astextplain | ||
*.rtf diff=astextplain | ||
*.RTF diff=astextplain | ||
############################################################################### | ||
# Set the merge driver for project and solution files | ||
# | ||
# Merging from the command prompt will add diff markers to the files if there | ||
# are conflicts (Merging from VS is not affected by the settings below, in VS | ||
# the diff markers are never inserted). Diff markers may cause the following | ||
# file extensions to fail to load in VS. An alternative would be to treat | ||
# these files as binary and thus will always conflict and require user | ||
# intervention with every merge. To do so, just uncomment the entries below | ||
############################################################################### | ||
#*.sln merge=binary | ||
#*.csproj merge=binary | ||
#*.vbproj merge=binary | ||
#*.vcxproj merge=binary | ||
#*.vcproj merge=binary | ||
#*.dbproj merge=binary | ||
#*.fsproj merge=binary | ||
#*.lsproj merge=binary | ||
#*.wixproj merge=binary | ||
#*.modelproj merge=binary | ||
#*.sqlproj merge=binary | ||
#*.wwaproj merge=binary | ||
|
||
############################################################################### | ||
# behavior for image files | ||
# | ||
# image files are treated as binary by default. | ||
############################################################################### | ||
#*.jpg binary | ||
#*.png binary | ||
#*.gif binary | ||
|
||
############################################################################### | ||
# diff behavior for common document formats | ||
# | ||
# Convert binary document formats to text before diffing them. This feature | ||
# is only available from the command line. Turn it on by uncommenting the | ||
# entries below. | ||
############################################################################### | ||
#*.doc diff=astextplain | ||
#*.DOC diff=astextplain | ||
#*.docx diff=astextplain | ||
#*.DOCX diff=astextplain | ||
#*.dot diff=astextplain | ||
#*.DOT diff=astextplain | ||
#*.pdf diff=astextplain | ||
#*.PDF diff=astextplain | ||
#*.rtf diff=astextplain | ||
#*.RTF diff=astextplain |
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,78 @@ | ||
name: SerialPortRx CI-BuildOnly | ||
|
||
on: | ||
pull_request: | ||
branches: [ "master" ] | ||
|
||
jobs: | ||
ci-build-and-test: | ||
|
||
runs-on: windows-2022 | ||
outputs: | ||
nbgv: ${{ steps.nbgv.outputs.SemVer2 }} | ||
steps: | ||
- name: Get Current Visual Studio Information | ||
shell: bash | ||
run: | | ||
dotnet tool update -g dotnet-vs | ||
echo "-- About RELEASE --" | ||
vs where release | ||
- name: Update Visual Studio Latest Release | ||
shell: bash | ||
run: | | ||
echo "-- Update RELEASE --" | ||
vs update release Enterprise | ||
vs modify release Enterprise +mobile +desktop +uwp +web | ||
echo "-- About RELEASE Updated --" | ||
vs where release | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # avoid shallow clone so nbgv can do its work. | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
- name: Add MSBuild to PATH | ||
uses: microsoft/[email protected] | ||
with: | ||
vs-prerelease: true | ||
|
||
- name: NBGV | ||
id: nbgv | ||
uses: dotnet/nbgv@master | ||
with: | ||
setAllVars: true | ||
- run: echo 'SemVer2=${{ steps.nbgv.outputs.SemVer2 }}' | ||
|
||
- name: NuGet Restore | ||
run: dotnet restore SerialPortRx.sln | ||
working-directory: src | ||
|
||
- name: Build | ||
run: msbuild /t:build,pack /nowarn:MSB4011 /maxcpucount /p:NoPackageAnalysis=true /verbosity:minimal /p:Configuration=Release SerialPortRx.sln | ||
working-directory: src | ||
|
||
- name: Run Unit Tests and Generate Coverage | ||
uses: glennawatson/[email protected] | ||
with: | ||
project-files: 'src/**/*Tests*.csproj' | ||
no-build: true | ||
include-filter: 'SerialPortRx*' | ||
output-format: cobertura | ||
configuration: Release | ||
|
||
- name: Upload Code Coverage | ||
uses: codecov/codecov-action@v3 | ||
|
||
- name: Create NuGet Artifacts | ||
uses: actions/upload-artifact@master | ||
with: | ||
name: nuget | ||
path: '**/*.nupkg' |
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,87 @@ | ||
name: SerialPortRx CI-Build | ||
|
||
on: | ||
push: | ||
branches: [ "master" ] | ||
|
||
jobs: | ||
build-and-release: | ||
|
||
runs-on: windows-2022 | ||
outputs: | ||
nbgv: ${{ steps.nbgv.outputs.SemVer2 }} | ||
steps: | ||
- name: Get Current Visual Studio Information | ||
shell: bash | ||
run: | | ||
dotnet tool update -g dotnet-vs | ||
echo "-- About RELEASE --" | ||
vs where release | ||
- name: Update Visual Studio Latest Release | ||
shell: bash | ||
run: | | ||
echo "-- Update RELEASE --" | ||
vs update release Enterprise | ||
vs modify release Enterprise +mobile +desktop +uwp +web | ||
echo "-- About RELEASE Updated --" | ||
vs where release | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # avoid shallow clone so nbgv can do its work. | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
- name: Add MSBuild to PATH | ||
uses: microsoft/[email protected] | ||
with: | ||
vs-prerelease: true | ||
|
||
- name: NBGV | ||
id: nbgv | ||
uses: dotnet/nbgv@master | ||
with: | ||
setAllVars: true | ||
- run: echo 'SemVer2=${{ steps.nbgv.outputs.SemVer2 }}' | ||
|
||
- name: NuGet Restore | ||
run: dotnet restore SerialPortRx.sln | ||
working-directory: src | ||
|
||
- name: Build | ||
run: msbuild /t:build,pack /nowarn:MSB4011 /maxcpucount /p:NoPackageAnalysis=true /verbosity:minimal /p:Configuration=Release SerialPortRx.sln | ||
working-directory: src | ||
|
||
- name: Create NuGet Artifacts | ||
uses: actions/upload-artifact@master | ||
with: | ||
name: nuget | ||
path: '**/*.nupkg' | ||
|
||
- name: Changelog | ||
uses: glennawatson/ChangeLog@v1 | ||
id: changelog | ||
|
||
- name: Create Release | ||
uses: actions/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token | ||
with: | ||
tag_name: ${{ steps.nbgv.outputs.SemVer2 }} | ||
release_name: ${{ steps.nbgv.outputs.SemVer2 }} | ||
body: | | ||
${{ steps.changelog.outputs.commitLog }} | ||
- name: NuGet Push | ||
env: | ||
NUGET_AUTH_TOKEN: ${{ secrets.NUGET_API_KEY }} | ||
SOURCE_URL: https://api.nuget.org/v3/index.json | ||
run: | | ||
dotnet nuget push -s ${{ env.SOURCE_URL }} -k ${{ env.NUGET_AUTH_TOKEN }} **/*.nupkg --skip-duplicate |
Oops, something went wrong.