Use cmd shell for Windows manual workflow
manual-pdf / build-manual (push) Failing after 21s

This commit is contained in:
2026-10-13 14:43:11 -04:00
parent fbc37e6dcd
commit a3c51e570a
+8 -17
View File
@@ -16,28 +16,19 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Generate build metadata - name: Generate build metadata
shell: powershell shell: cmd
run: | run: |
$shortSha = $env:GITHUB_SHA.Substring(0, 7) echo \renewcommand{\BuildIdentifier}{+build.%GITHUB_RUN_NUMBER%.%GITHUB_SHA:~0,7%}> devopsBuildMetadata.tex
$runNumber = $env:GITHUB_RUN_NUMBER echo \renewcommand{\SourceRevision}{%GITHUB_SHA:~0,7%}>> devopsBuildMetadata.tex
$runAttempt = $env:GITHUB_RUN_ATTEMPT echo \renewcommand{\WorkflowRunNumber}{%GITHUB_RUN_NUMBER%}>> devopsBuildMetadata.tex
@" echo \renewcommand{\WorkflowRunAttempt}{%GITHUB_RUN_ATTEMPT%}>> devopsBuildMetadata.tex
\renewcommand{\BuildIdentifier}{+build.$runNumber.$shortSha}
\renewcommand{\SourceRevision}{$shortSha}
\renewcommand{\WorkflowRunNumber}{$runNumber}
\renewcommand{\WorkflowRunAttempt}{$runAttempt}
"@ | Set-Content -Path devopsBuildMetadata.tex -Encoding ASCII
- name: Compile manual - name: Compile manual
shell: powershell shell: cmd
run: | run: |
latexmk -norc -pdf -shell-escape -interaction=nonstopmode -halt-on-error devopsAssignment.tex latexmk -norc -pdf -shell-escape -interaction=nonstopmode -halt-on-error devopsAssignment.tex
if (-not (Test-Path devopsAssignment.pdf)) { if not exist devopsAssignment.pdf exit /b 1
throw "Expected PDF was not produced." for %%A in (devopsAssignment.pdf) do if %%~zA LEQ 0 exit /b 1
}
if ((Get-Item devopsAssignment.pdf).Length -le 0) {
throw "Expected PDF is empty."
}
- name: Upload compiled PDF - name: Upload compiled PDF
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3