Skip to content

Commit a7e3c3f

Browse files
committed
尝试修复CI
1 parent fab647f commit a7e3c3f

File tree

3 files changed

+11
-21
lines changed

3 files changed

+11
-21
lines changed

.github/workflows/ci-plugin.yml

-7
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,6 @@ on:
88
- '.github/workflows/ci-plugin.yml'
99
- 'src/Plugins/**'
1010
- 'build-plugin.cake'
11-
pull_request:
12-
branches:
13-
- preview
14-
paths:
15-
- '.github/workflows/ci-plugin.yml'
16-
- 'src/Plugins/**'
17-
- 'build-plugin.cake'
1811
jobs:
1912
build:
2013
runs-on: ubuntu-latest

.github/workflows/ci.yml

+1-8
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,6 @@ on:
88
- '.github/workflows/ci.yml'
99
- 'src/Impostor*/**'
1010
- 'build.cake'
11-
pull_request:
12-
branches:
13-
- preview
14-
paths:
15-
- '.github/workflows/ci.yml'
16-
- 'src/Impostor*/**'
17-
- 'build.cake'
1811
jobs:
1912
build:
2013
runs-on: ubuntu-latest
@@ -44,5 +37,5 @@ jobs:
4437

4538
- name: Publish to NuGet
4639
run: |
47-
dotnet nuget push ./build/*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NUGETKEY }}
40+
dotnet nuget push "./build/*.nupkg" -s https://api.nuget.org/v3/index.json -k ${{ secrets.NUGETKEY }}
4841

build-plugin.cake

+10-6
Original file line numberDiff line numberDiff line change
@@ -48,21 +48,25 @@ Task("Build")
4848
.IsDependentOn("Restore")
4949
.Does(() => {
5050
DotNetBuild("./src/Plugins/SelfHttpMatchmaker/SelfHttpMatchmaker.csproj", new DotNetBuildSettings {
51-
OutputDirectory = buildDir,
5251
Configuration = configuration,
53-
MSBuildSettings = msbuildSettings
52+
NoRestore = true,
53+
Runtime = runtime,
54+
OutputDirectory = buildDir + "/SelfHttpMatchmaker",
55+
MSBuildSettings = msbuildSettings,
5456
});
5557

5658
DotNetBuild("./src/Plugins/GameCodePlugin/GameCodePlugin.csproj", new DotNetBuildSettings {
57-
OutputDirectory = buildDir,
5859
Configuration = configuration,
59-
MSBuildSettings = msbuildSettings
60+
NoRestore = true,
61+
Runtime = runtime,
62+
OutputDirectory = buildDir + "/GameCodePlugin",
63+
MSBuildSettings = msbuildSettings,
6064
});
6165

6266
if (BuildSystem.GitHubActions.IsRunningOnGitHubActions) {
63-
BuildSystem.GitHubActions.Commands.UploadArtifact(buildDir + "/SelfHttpMatchmaker.dll", "SelfHttpMatchmaker");
67+
BuildSystem.GitHubActions.Commands.UploadArtifact(buildDir + "/SelfHttpMatchmaker", "SelfHttpMatchmaker");
6468

65-
BuildSystem.GitHubActions.Commands.UploadArtifact(buildDir + "/GameCodePlugin.dll", "GameCodePlugin");
69+
BuildSystem.GitHubActions.Commands.UploadArtifact(buildDir + "/GameCodePlugin", "GameCodePlugin");
6670
}
6771
});
6872

0 commit comments

Comments
 (0)