Skip to content

Commit 0bcaf24

Browse files
authored
Merge pull request #119 from Erol444/fix-13-06-2022
Fix 13 06 2022
2 parents 913fef5 + e0c7939 commit 0bcaf24

File tree

2 files changed

+15
-51
lines changed

2 files changed

+15
-51
lines changed

.github/workflows/pre-release.yml

Lines changed: 9 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -48,43 +48,25 @@ jobs:
4848
runs-on: windows-2019
4949
needs: version
5050
steps:
51-
- name: setup-msbuild
52-
uses: microsoft/setup-msbuild@v1
53-
54-
- uses: actions/checkout@v2
55-
56-
- name: Setup NuGet
57-
uses: NuGet/[email protected]
51+
- name: Setup dotnet
52+
uses: actions/setup-dotnet@v2
53+
with:
54+
dotnet-version: 6.0.x
5855

56+
- name: 'Checkout repo'
57+
uses: actions/checkout@v2
58+
5959
- name: Navigate to Workspace
6060
run: cd $GITHUB_WORKSPACE
6161

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-
7962
- name: Build Bot
8063
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
8365
- name: Upload a Build Artifact
8466
uses: actions/upload-artifact@v2
8567
with:
8668
name: TBS-prerelease
87-
path: TravBotSharp\bin\Release
69+
path: TbsWinformNet6\bin\Release\net6.0-windows\win-x86\publish\
8870
if-no-files-found: error
8971

9072
prerelease:

.github/workflows/release.yml

Lines changed: 6 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -49,44 +49,26 @@ jobs:
4949
runs-on: windows-2019
5050
needs: version
5151
steps:
52-
- name: setup-msbuild
53-
uses: microsoft/setup-msbuild@v1
54-
55-
- name: Setup NuGet
56-
uses: NuGet/[email protected]
52+
- name: Setup dotnet
53+
uses: actions/setup-dotnet@v2
54+
with:
55+
dotnet-version: 6.0.x
5756

5857
- name: 'Checkout repo'
5958
uses: actions/checkout@v2
6059

6160
- name: Navigate to Workspace
6261
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
8062

8163
- name: Build Bot
8264
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
8466
8567
- name: Upload a Build Artifact
8668
uses: actions/upload-artifact@v2
8769
with:
8870
name: TBS-release
89-
path: TravBotSharp\bin\Release
71+
path: TbsWinformNet6\bin\Release\net6.0-windows\win-x86\publish\
9072
if-no-files-found: error
9173

9274
release:

0 commit comments

Comments
 (0)