Skip to content

Run workflow on pushes to my branch #2

Run workflow on pushes to my branch

Run workflow on pushes to my branch #2

on:
push:
branches: [ master, cesm3.0-alphabranch, add_preview_namelist_CI ]
pull_request:
branches: [ master, cesm3.0-alphabranch ]
jobs:
preview_namelists:
runs-on: ubuntu-latest
strategy:
matrix:
# Lots of python versions, pare down if we don't support a version
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
config: [{"compset": "BLT1850", "res": "ne30pg3_t232"},
{"compset": "C_JRA", "res": "TL319_t232"},
{"compset": "D", "res": null},
{"compset": "FTJ16", "res": null},
{"compset": "I2000Clm60SpRs", "res": null}]
steps:
- id: checkout-CESM
uses: actions/checkout@v4
- id: Setup python ${{ matrix.python-version }}

Check failure on line 21 in .github/workflows/preview_namelist.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/preview_namelist.yaml

Invalid workflow file

The workflow is not valid. .github/workflows/preview_namelist.yaml (Line: 21, Col: 13): Unrecognized named-value: 'matrix'. Located at position 1 within expression: matrix.python-version
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- id: Create new case, run case.setup, and then preview namelists
run: |
$GITHUB_WORKSPACE/bin/git-fleximod update
cd $GITHUB_WORKSPACE/cime/scripts
./create_newcase --run-unsupported --compset ${{ matrix.config.compset }} --res ${{ matrix.config.res }} --case $GITHUB_WORKSPACE/cases/${{ matrix.config.compset }}_${{ matrix.config.python-version }}
cd $GITHUB_WORKSPACE/cases/${{ matrix.config.compset }}_${{ matrix.config.python-version }}
./case.setup
./preview_namelists