Skip to content

Commit

Permalink
#318 Separate Failure handling on Windows and Unixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ascheman authored and Gerd Aschemann (EXT) committed Nov 19, 2024
1 parent c0e110d commit 35f275d
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 8 deletions.
17 changes: 15 additions & 2 deletions .github/workflows/build-artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ jobs:
path: |
**/build
- name: Collect state upon failure
if: failure()
- name: Collect state upon failure (On Unix)
if: failure() && runner.os != 'Windows'
run: |
echo "Git:"
git status
Expand All @@ -86,3 +86,16 @@ jobs:
pwd
echo "Files:"
find * -ls
- name: Collect state upon failure (On Windows)
if: failure() && runner.os == 'Windows'
shell: pwsh
run: |
echo "Git:"
git status
echo "Env:"
env
echo "PWD:"
pwd
echo "Files:"
Get-ChildItem -Recurse -File | Format-Table Name, Length, LastWriteTime
21 changes: 15 additions & 6 deletions .github/workflows/test-java-os-mix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,8 @@ jobs:
cmd /c "echo off && gradlew.bat --version"
cmd /c "echo off && gradlew.bat htmlSanityCheck --scan"
# If we ever need to debug the file system contents
# Get-ChildItem -Recurse -File | Format-Table Name, Length, LastWriteTime
# Get-ChildItem -Recurse -File ./integration-test | Format-Table Name, Length, LastWriteTime

- name: Collect state upon failure
if: failure()
- name: Collect state upon failure (On Unix)
if: failure() && runner.os != 'Windows'
run: |
echo "Git:"
git status
Expand All @@ -72,3 +68,16 @@ jobs:
pwd
echo "Files:"
find * -ls
- name: Collect state upon failure (On Windows)
if: failure() && runner.os == 'Windows'
shell: pwsh
run: |
echo "Git:"
git status
echo "Env:"
env
echo "PWD:"
pwd
echo "Files:"
Get-ChildItem -Recurse -File | Format-Table Name, Length, LastWriteTime

0 comments on commit 35f275d

Please sign in to comment.