Skip to content

Commit 915c733

Browse files
committed
Fix github action
1 parent d921989 commit 915c733

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

.github/workflows/Build-WeChatFerry.yml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ jobs:
4646
path: |
4747
C:/Tools/vcpkg
4848
${{ github.workspace }}/WeChatFerry/vcpkg_installed
49-
key: ${{ runner.os }}-vcpkg-${{ hashFiles('WeChatFerry/vcpkg.json') }}
49+
key: vcpkg-${{ hashFiles('WeChatFerry/vcpkg.json') }}
5050
restore-keys: |
51-
${{ runner.os }}-vcpkg-
51+
vcpkg-
5252
5353
- name: 安装 vcpkg 并初始化依赖项
5454
run: |
@@ -68,19 +68,24 @@ jobs:
6868
echo "VCPKG_ROOT=C:/Tools/vcpkg" >> $GITHUB_ENV
6969
$env:VCPKG_ROOT = 'C:/Tools/vcpkg'
7070
71-
# 将 vcpkg 与 Visual Studio 集成
72-
C:/Tools/vcpkg/vcpkg integrate install
73-
7471
# 返回到项目目录并安装依赖
7572
cd ${{ github.workspace }}/WeChatFerry
76-
C:/Tools/vcpkg/vcpkg install --triplet x64-windows-static
73+
C:/Tools/vcpkg/vcpkg install --triplet x64-windows-static --manifest
74+
75+
# 将 vcpkg 与 Visual Studio 集成
76+
C:/Tools/vcpkg/vcpkg integrate install
7777
7878
- name: 解析并构建配置
7979
run: |
8080
$configurations = "Release,Debug".Split(',')
8181
foreach ($config in $configurations) {
8282
Write-Host "Building configuration: $config"
83-
msbuild WeChatFerry/WeChatFerry.sln /p:Configuration=$config /p:Platform="x64" /p:VcpkgTriplet="x64-windows-static" /p:VcpkgEnableManifest=true /verbosity:minimal
83+
msbuild WeChatFerry/WeChatFerry.sln `
84+
/p:Configuration=$config `
85+
/p:Platform="x64" `
86+
/p:VcpkgTriplet="x64-windows-static" `
87+
/p:VcpkgEnableManifest=true `
88+
/verbosity:minimal
8489
}
8590
shell: pwsh
8691

0 commit comments

Comments
 (0)