Skip to content

Commit a501019

Browse files
authored
Merge pull request #1936 from microsoft/milestones/m273
Release M273
2 parents 3439a86 + 31312ad commit a501019

95 files changed

Lines changed: 9603 additions & 1133 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/build.yaml

Lines changed: 66 additions & 114 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
name: VFS for Git
22

3+
run-name: ${{ inputs.run_name || 'VFS for Git' }}
4+
35
on:
46
pull_request:
57
branches: [ master, releases/shipped ]
@@ -11,12 +13,17 @@ on:
1113
description: 'Microsoft Git version tag to include in the build (leave empty for default)'
1214
required: false
1315
type: string
16+
run_name:
17+
description: 'Optional display name for this run (used for cross-repo automation)'
18+
required: false
19+
type: string
1420

1521
permissions:
1622
contents: read
23+
actions: read
1724

1825
env:
19-
GIT_VERSION: ${{ github.event.inputs.git_version || 'v2.50.1.vfs.0.1' }}
26+
GIT_VERSION: ${{ github.event.inputs.git_version || 'v2.53.0.vfs.0.6' }}
2027

2128
jobs:
2229
validate:
@@ -93,7 +100,10 @@ jobs:
93100
}
94101
}
95102
96-
if (run.status === 'completed' && run.conclusion === 'success') return run.html_url
103+
if (run.status === 'completed' && run.conclusion === 'success') {
104+
core.notice(`Skipping: There already is a successful run: ${run.html_url}`)
105+
return run.html_url
106+
}
97107
}
98108
return ''
99109
} catch (e) {
@@ -116,6 +126,48 @@ jobs:
116126
-Tag $env:GIT_VERSION && `
117127
Write-Host ::notice title=Validation::Using microsoft/git version $env:GIT_VERSION
118128
129+
- name: Download microsoft/git installers
130+
if: steps.check.outputs.result == ''
131+
shell: cmd
132+
env:
133+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
134+
run: |
135+
gh release download %GIT_VERSION% --repo microsoft/git --pattern "Git*.exe" --dir MicrosoftGit
136+
137+
- name: Create Git install script
138+
if: steps.check.outputs.result == ''
139+
shell: cmd
140+
run: |
141+
>MicrosoftGit\install.bat (
142+
echo @ECHO OFF
143+
echo SETLOCAL
144+
echo.
145+
echo IF "%%PROCESSOR_ARCHITECTURE%%"=="AMD64" ^(
146+
echo SET GIT_ARCH=64-bit
147+
echo ^) ELSE IF "%%PROCESSOR_ARCHITECTURE%%"=="ARM64" ^(
148+
echo SET GIT_ARCH=arm64
149+
echo ^) ELSE ^(
150+
echo ECHO Unknown architecture: %%PROCESSOR_ARCHITECTURE%%
151+
echo exit 1
152+
echo ^)
153+
echo.
154+
echo FOR /F "tokens=* USEBACKQ" %%%%F IN ^( `where /R %%~dp0 Git*-%%GIT_ARCH%%.exe` ^) DO SET GIT_INSTALLER=%%%%F
155+
echo.
156+
echo SET LOGDIR=%%~dp0\logs
157+
echo IF EXIST %%LOGDIR%% ^( rmdir /S /Q %%LOGDIR%% ^)
158+
echo mkdir %%LOGDIR%%
159+
echo.
160+
echo ECHO Installing Git ^(%%GIT_ARCH%%^)...
161+
echo %%GIT_INSTALLER%% /LOG="%%LOGDIR%%\git.log" /VERYSILENT /SUPPRESSMSGBOXES /NORESTART /ALLOWDOWNGRADE=1
162+
)
163+
164+
- name: Upload microsoft/git installers
165+
if: steps.check.outputs.result == ''
166+
uses: actions/upload-artifact@v7
167+
with:
168+
name: MicrosoftGit
169+
path: MicrosoftGit
170+
119171
build:
120172
runs-on: windows-2025
121173
name: Build and Unit Test
@@ -150,7 +202,7 @@ jobs:
150202

151203
- name: Add MSBuild to PATH
152204
if: steps.skip.outputs.result != 'true'
153-
uses: microsoft/setup-msbuild@v2.0.0
205+
uses: microsoft/setup-msbuild@v3.0.0
154206

155207
- name: Build VFS for Git
156208
if: steps.skip.outputs.result != 'true'
@@ -167,139 +219,39 @@ jobs:
167219
shell: cmd
168220
run: src\scripts\CreateBuildArtifacts.bat ${{ matrix.configuration }} artifacts
169221

170-
- name: Download microsoft/git installers
171-
if: steps.skip.outputs.result != 'true'
172-
shell: cmd
173-
env:
174-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
175-
run: |
176-
gh release download %GIT_VERSION% --repo microsoft/git --pattern "Git*.exe" --dir artifacts\GVFS.Installers
177-
178222
- name: Upload functional tests drop
179223
if: steps.skip.outputs.result != 'true'
180-
uses: actions/upload-artifact@v6
224+
uses: actions/upload-artifact@v7
181225
with:
182226
name: FunctionalTests_${{ matrix.configuration }}
183227
path: artifacts\GVFS.FunctionalTests
184228

185229
- name: Upload FastFetch drop
186230
if: steps.skip.outputs.result != 'true'
187-
uses: actions/upload-artifact@v6
231+
uses: actions/upload-artifact@v7
188232
with:
189233
name: FastFetch_${{ matrix.configuration }}
190234
path: artifacts\FastFetch
191235

192-
- name: Upload installers
236+
- name: Upload GVFS installer
193237
if: steps.skip.outputs.result != 'true'
194-
uses: actions/upload-artifact@v6
238+
uses: actions/upload-artifact@v7
195239
with:
196-
name: Installers_${{ matrix.configuration }}
240+
name: GVFS_${{ matrix.configuration }}
197241
path: artifacts\GVFS.Installers
198242

199-
functional_test:
200-
runs-on: ${{ matrix.architecture == 'arm64' && 'windows-11-arm' || 'windows-2025' }}
243+
functional_tests:
201244
name: Functional Tests
202245
needs: [validate, build]
203-
204-
strategy:
205-
matrix:
206-
configuration: [ Debug, Release ]
207-
architecture: [ x86_64, arm64 ]
208-
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] # 10 parallel jobs to speed up the tests
209-
fail-fast: false # most failures are flaky tests, no need to stop the other jobs from succeeding
210-
211-
steps:
212-
- name: Skip this job if there is a previous successful run
213-
if: needs.validate.outputs.skip != ''
214-
id: skip
215-
uses: actions/github-script@v8
216-
with:
217-
script: |
218-
core.info(`Skipping: There already is a successful run: ${{ needs.validate.outputs.skip }}`)
219-
return true
220-
221-
- name: Download installers
222-
if: steps.skip.outputs.result != 'true'
223-
uses: actions/download-artifact@v7
224-
with:
225-
name: Installers_${{ matrix.configuration }}
226-
path: install
227-
228-
- name: Download functional tests drop
229-
if: steps.skip.outputs.result != 'true'
230-
uses: actions/download-artifact@v7
231-
with:
232-
name: FunctionalTests_${{ matrix.configuration }}
233-
path: ft
234-
235-
- name: ProjFS details (pre-install)
236-
if: steps.skip.outputs.result != 'true'
237-
shell: cmd
238-
run: install\info.bat
239-
240-
- name: Install product
241-
if: steps.skip.outputs.result != 'true'
242-
shell: cmd
243-
run: install\install.bat
244-
245-
- name: ProjFS details (post-install)
246-
if: steps.skip.outputs.result != 'true'
247-
shell: cmd
248-
run: install\info.bat
249-
250-
- name: Upload installation logs
251-
if: always() && steps.skip.outputs.result != 'true'
252-
uses: actions/upload-artifact@v6
253-
with:
254-
name: InstallationLogs_${{ matrix.configuration }}_${{ matrix.architecture }}-${{ matrix.nr }}
255-
path: install\logs
256-
257-
- name: Run functional tests
258-
if: steps.skip.outputs.result != 'true'
259-
shell: cmd
260-
run: |
261-
SET PATH=C:\Program Files\VFS for Git;%PATH%
262-
SET GIT_TRACE2_PERF=C:\temp\git-trace2.log
263-
ft\GVFS.FunctionalTests.exe /result:TestResult.xml --ci --slice=${{ matrix.nr }},10
264-
265-
- name: Upload functional test results
266-
if: always() && steps.skip.outputs.result != 'true'
267-
uses: actions/upload-artifact@v6
268-
with:
269-
name: FunctionalTests_Results_${{ matrix.configuration }}_${{ matrix.architecture }}-${{ matrix.nr }}
270-
path: TestResult.xml
271-
272-
- name: Upload Git trace2 output
273-
if: always() && steps.skip.outputs.result != 'true'
274-
uses: actions/upload-artifact@v6
275-
with:
276-
name: GitTrace2_${{ matrix.configuration }}_${{ matrix.architecture }}-${{ matrix.nr }}
277-
path: C:\temp\git-trace2.log
278-
279-
- name: ProjFS details (post-test)
280-
if: always() && steps.skip.outputs.result != 'true'
281-
shell: cmd
282-
run: install\info.bat
283-
284-
ft_results:
285-
runs-on: ubuntu-latest # quickest runners
286-
name: Functional Tests
287-
needs: [functional_test]
288-
289-
strategy:
290-
matrix:
291-
configuration: [ Debug, Release ]
292-
architecture: [ x86_64, arm64 ]
293-
294-
steps:
295-
- name: Success! # for easier identification of successful runs in the Checks Required for Pull Requests
296-
run: echo "All functional test jobs successful for ${{ matrix.configuration }} / ${{ matrix.architecture }}!"
246+
uses: ./.github/workflows/functional-tests.yaml
247+
with:
248+
skip: ${{ needs.validate.outputs.skip }}
297249

298250
result:
299251
runs-on: ubuntu-latest
300252
name: Build, Unit and Functional Tests Successful
301-
needs: [functional_test]
253+
needs: [functional_tests]
302254

303255
steps:
304256
- name: Success! # for easier identification of successful runs in the Checks Required for Pull Requests
305-
run: echo "Workflow run is successful!"
257+
run: echo "Workflow run is successful!"

0 commit comments

Comments
 (0)