Skip to content

Commit

Permalink
Update manual-matrix.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
tsubakimoto authored Jun 25, 2024
1 parent 71c0eca commit a718d7c
Showing 1 changed file with 31 additions and 8 deletions.
39 changes: 31 additions & 8 deletions .github/workflows/manual-matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,36 @@ jobs:
# os: [ ubuntu-latest, ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, windows-latest, windows-2022, windows-2019, macos-latest, macos-latest-large, macos-latest-xlarge, macos-11, macos-12, macos-12-large, macos-13, macos-13-large, macos-13-xlarge, macos-14, macos-14-large, macos-14-xlarge ]
runs-on: ${{ matrix.os }}
steps:
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.x

- name: Display OS info
id: display
run: |
import platform;
print(f'Hello ${{ github.event.inputs.name }} on ${{ matrix.os }}')
print(f'OS: {platform.system()}')
print(f'Release: {platform.release()}')
print(f'Version: {platform.version()}')
print(f'Machine: {platform.machine()}')
print(f'Processor: {platform.processor()}')
shell: python
OS_INFO=$(python -c "import platform; print(f'OS: {platform.system()}')")
RELEASE_INFO=$(python -c "import platform; print(f'Release: {platform.release()}')")
VERSION_INFO=$(python -c "import platform; print(f'Version: {platform.version()}')")
MACHINE_INFO=$(python -c "import platform; print(f'Machine: {platform.machine()}')")
PROCESSOR_INFO=$(python -c "import platform; print(f'Processor: {platform.processor()}')")
echo "os-info=$OS_INFO" >> "$GITHUB_OUTPUT"
echo "release-info=$RELEASE_INFO" >> "$GITHUB_OUTPUT"
echo "version-info=$VERSION_INFO" >> "$GITHUB_OUTPUT"
echo "machine-info=$MACHINE_INFO" >> "$GITHUB_OUTPUT"
echo "processor-info=$PROCESSOR_INFO" >> "$GITHUB_OUTPUT"
- name: Summary
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
import * as core from '@actions/core'
await core.summary
.addHeading('OS Information')
.addCodeBlock(generateTestResults(), "js")
.addTable([
[{data: 'Runner', header: true}, {data: 'OS', header: true}, {data: 'Release', header: true}, {data: 'Version', header: true}, {data: 'Machine', header: true}, {data: 'Processor', header: true}],
['${{ matrix.os }}', '${{ steps.display.outputs.os-info }}', '${{ steps.display.outputs.release-info }}', ${{ steps.display.outputs.version-info }}, ${{ steps.display.outputs.machine-info }}, ${{ steps.display.outputs.processor-info }}]
])
.write()

0 comments on commit a718d7c

Please sign in to comment.