Skip to content

Commit 5aaedc0

Browse files
committed
Re-ordered vcpkg related steps. It may be affected with VsDevCmd.bat
1 parent 80bf074 commit 5aaedc0

1 file changed

Lines changed: 19 additions & 19 deletions

File tree

.github/workflows/windows.yml

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,16 @@ jobs:
6868
bundler: none
6969
windows-toolchain: none
7070

71+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
72+
with:
73+
sparse-checkout-cone-mode: false
74+
sparse-checkout: /.github
75+
76+
- uses: ./.github/actions/setup/directories
77+
with:
78+
srcdir: src
79+
builddir: build
80+
7181
- name: Install tools with scoop
7282
run: |
7383
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
@@ -76,15 +86,17 @@ jobs:
7686
scoop install vcpkg uutils-coreutils cmake@3.31.6
7787
shell: pwsh
7888

79-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
89+
# vcpkg built-in cache is not working now
90+
- name: Restore vcpkg artifact
91+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
8092
with:
81-
sparse-checkout-cone-mode: false
82-
sparse-checkout: /.github
93+
path: src\vcpkg_installed
94+
key: windows-${{ matrix.os }}-vcpkg-${{ hashFiles('src/vcpkg.json') }}
8395

84-
- uses: ./.github/actions/setup/directories
85-
with:
86-
srcdir: src
87-
builddir: build
96+
- name: Install libraries with vcpkg
97+
run: |
98+
vcpkg install --vcpkg-root=C:\Users\runneradmin\scoop\apps\vcpkg\current
99+
working-directory: src
88100

89101
- name: setup env
90102
# Available Ruby versions: https://github.com/actions/runner-images/blob/main/images/windows/Windows2019-Readme.md#ruby
@@ -116,18 +128,6 @@ jobs:
116128
run: Get-Volume
117129
shell: pwsh
118130

119-
# vcpkg built-in cache is not working now
120-
- name: Restore vcpkg artifact
121-
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
122-
with:
123-
path: src\vcpkg_installed
124-
key: windows-${{ matrix.os }}-vcpkg-${{ hashFiles('src/vcpkg.json') }}
125-
126-
- name: Install libraries with vcpkg
127-
run: |
128-
vcpkg install --vcpkg-root=C:\Users\runneradmin\scoop\apps\vcpkg\current
129-
working-directory: src
130-
131131
# TODO: We should use `../src` instead of `D:/a/ruby/ruby/src`
132132
- name: Configure
133133
run: >-

0 commit comments

Comments
 (0)