Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ jobs:
runs-on: ubuntu-24.04
steps:
- name: checkout
uses: actions/checkout@v5
uses: actions/checkout@v6
with: { submodules: recursive }
- uses: prefix-dev/setup-pixi@v0.9.3
with:
pixi-version: v0.49.0
pixi-version: v0.63.2
- name: digitize
shell: pixi run bash -e {0}
run: pixi run -e dev convert
- name: validate packages
shell: pixi run bash -e {0}
run: pixi run -e dev validate
- name: upload data artifact
uses: actions/upload-artifact@v5
uses: actions/upload-artifact@v6
with:
name: data-${{ github.event.pull_request.number }}
path: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
steps:
- name: checkout
uses: actions/checkout@v5
uses: actions/checkout@v6
with: { submodules: recursive }
- uses: prefix-dev/setup-pixi@v0.9.3
with:
pixi-version: v0.49.0
pixi-version: v0.63.2
- name: doctest
shell: pixi run bash -e {0}
run: pixi run -e ${{ matrix.environment }} doctest
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v5
uses: actions/checkout@v6
with: { submodules: recursive }
- uses: prefix-dev/setup-pixi@v0.9.3
with:
pixi-version: v0.49.0
pixi-version: v0.63.2
- name: validate input yaml
shell: pixi run bash -e {0}
run: pixi run -e dev validate-yaml
17 changes: 15 additions & 2 deletions pixi.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ packages = [
"echemdb_ecdata",
]

[tool.pixi.project]
[tool.pixi.workspace]
channels = ["conda-forge"]
platforms = ["linux-64", "osx-64", "win-64"]

Expand Down Expand Up @@ -66,8 +66,9 @@ pytest-remotedata = "*"
convert = "cd data && make -j$(nproc)"
# To validate the metadata against a specific version preceded the version by `tags` such as `tags/0.3.1`.
# To validate the metadata against metadata in a specific branch use `head/branch-name`.
validate = { args = [ { "arg" = "version", "default" = "tags/0.3.1" } ],cmd = "check-jsonschema --schemafile https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/echemdb_package.json --base-uri https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/echemdb_package.json --no-cache $(find ./data/generated/svgdigitizer/ -type f -name '*.json')" }
validate-yaml = { args = [ { "arg" = "version", "default" = "tags/0.3.1" } ], cmd = "check-jsonschema --schemafile https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/svgdigitizer.json --base-uri https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/svgdigitizer.json --no-cache $(find ./literature/svgdigitizer/ -type f -name '*.yaml')" }
# Run `check-jsonschema` only if JSON files exist; otherwise print a message.
validate = { args = [ { "arg" = "version", "default" = "tags/0.3.2" } ], cmd = "sh -c \"if find ./data/generated/svgdigitizer/ -type f -name '*.json' -print -quit 2>/dev/null | grep -q .; then find ./data/generated/svgdigitizer/ -type f -name '*.json' -print0 | xargs -0 check-jsonschema --schemafile https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/echemdb_package.json --base-uri https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/echemdb_package.json --no-cache; else echo 'No JSON files to validate'; fi\"" }
validate-yaml = { args = [ { "arg" = "version", "default" = "tags/0.3.2" } ], cmd = "sh -c \"if find ./literature/svgdigitizer/ -type f -name '*.yaml' -print -quit 2>/dev/null | grep -q .; then find ./literature/svgdigitizer/ -type f -name '*.yaml' -print0 | xargs -0 check-jsonschema --schemafile https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/svgdigitizer.json --base-uri https://raw.githubusercontent.com/echemdb/metadata-schema/refs/{{ version }}/schemas/svgdigitizer.json --no-cache; else echo 'No YAML files to validate'; fi\"" }
doctest = "pytest -n auto --doctest-modules echemdb_ecdata"

[tool.pixi.feature.lint.dependencies]
Expand Down
Loading