File tree Expand file tree Collapse file tree 2 files changed +15
-51
lines changed Expand file tree Collapse file tree 2 files changed +15
-51
lines changed Original file line number Diff line number Diff line change @@ -48,43 +48,25 @@ jobs:
48
48
runs-on : windows-2019
49
49
needs : version
50
50
steps :
51
- - name : setup-msbuild
52
- uses : microsoft/setup-msbuild@v1
53
-
54
- - uses : actions/checkout@v2
55
-
56
- - name : Setup NuGet
57
-
51
+ - name : Setup dotnet
52
+ uses : actions/setup-dotnet@v2
53
+ with :
54
+ dotnet-version : 6.0.x
58
55
56
+ - name : ' Checkout repo'
57
+ uses : actions/checkout@v2
58
+
59
59
- name : Navigate to Workspace
60
60
run : cd $GITHUB_WORKSPACE
61
61
62
- - name : Get cache
63
- uses : actions/cache@v2
64
- with :
65
- path : |
66
- packages
67
- TbsCore/obj/project.assets.json
68
- TbsCore/TbsCore.csproj.nuget.g.targets
69
- TbsCore/TbsCore.csproj.nuget.g.props.
70
- key : ${{ runner.os }}-nuget-${{ hashFiles('TbsCore/packages.lock.json') }}
71
- restore-keys : |
72
- ${{ runner.os }}-nuget-
73
-
74
- - name : Restore Packages
75
- run : |
76
- nuget restore TbsCore/TbsCore.csproj -PackagesDirectory packages
77
- nuget restore TravBotSharp/TbsWinForms.csproj -PackagesDirectory packages
78
-
79
62
- name : Build Bot
80
63
run : |
81
- msbuild.exe TravBotSharp.sln /t:TbsWinForms /nologo /nr:false /p:DeleteExistingFiles=True /p:platform="Any CPU" /p:configuration="Release" /m /p:BuildProjectReferences=true /p:BUILD_NUMBER=${{needs.version.outputs.version}}.0
82
-
64
+ dotnet publish TbsWinformNet6 -c Release --self-contained true -p:PublishSingleFile=true -r win-x86 -p:AssemblyVersion=${{needs.version.outputs.version}}.0
83
65
- name : Upload a Build Artifact
84
66
uses : actions/upload-artifact@v2
85
67
with :
86
68
name : TBS-prerelease
87
- path : TravBotSharp \bin\Release
69
+ path : TbsWinformNet6 \bin\Release\net6.0-windows\win-x86\publish\
88
70
if-no-files-found : error
89
71
90
72
prerelease :
Original file line number Diff line number Diff line change @@ -49,44 +49,26 @@ jobs:
49
49
runs-on : windows-2019
50
50
needs : version
51
51
steps :
52
- - name : setup-msbuild
53
- uses : microsoft/setup-msbuild@v1
54
-
55
- - name : Setup NuGet
56
-
52
+ - name : Setup dotnet
53
+ uses : actions/setup-dotnet@v2
54
+ with :
55
+ dotnet-version : 6.0.x
57
56
58
57
- name : ' Checkout repo'
59
58
uses : actions/checkout@v2
60
59
61
60
- name : Navigate to Workspace
62
61
run : cd $GITHUB_WORKSPACE
63
-
64
- - name : Get cache
65
- uses : actions/cache@v2
66
- with :
67
- path : |
68
- packages
69
- TbsCore/obj/project.assets.json
70
- TbsCore/TbsCore.csproj.nuget.g.targets
71
- TbsCore/TbsCore.csproj.nuget.g.props.
72
- key : ${{ runner.os }}-nuget-${{ hashFiles('TbsCore/packages.lock.json') }}
73
- restore-keys : |
74
- ${{ runner.os }}-nuget-
75
-
76
- - name : Restore Packages
77
- run : |
78
- nuget restore TbsCore/TbsCore.csproj -PackagesDirectory packages
79
- nuget restore TravBotSharp/TbsWinForms.csproj -PackagesDirectory packages
80
62
81
63
- name : Build Bot
82
64
run : |
83
- msbuild.exe TravBotSharp.sln /t:TbsWinForms /nologo /nr:false /p:DeleteExistingFiles=True /p:platform="Any CPU" /p:configuration="Release" /m /p:BuildProjectReferences=true /p:BUILD_NUMBER =${{needs.version.outputs.version}}.0
65
+ dotnet publish TbsWinformNet6 -c Release --self-contained true -p:PublishSingleFile=true -r win-x86 -p:AssemblyVersion =${{needs.version.outputs.version}}.0
84
66
85
67
- name : Upload a Build Artifact
86
68
uses : actions/upload-artifact@v2
87
69
with :
88
70
name : TBS-release
89
- path : TravBotSharp \bin\Release
71
+ path : TbsWinformNet6 \bin\Release\net6.0-windows\win-x86\publish\
90
72
if-no-files-found : error
91
73
92
74
release :
You can’t perform that action at this time.
0 commit comments