Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use targets for windows specific pipeline #1731

Merged
merged 3 commits into from
Aug 15, 2024
Merged
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
24 changes: 14 additions & 10 deletions pixi.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,9 @@ test-ribasim-api = "pytest --basetemp=python/ribasim_api/tests/temp --junitxml=r
[feature.dev.tasks]
# Installation
install-julia = "juliaup add 1.10.4 && juliaup override unset && juliaup override set 1.10.4"
# Workaround rare issue, only on Windows, hence uses exit 0 to ignore errors
# Upstream issue: https://github.com/JuliaLang/julia/issues/52272
reset-artifact-permissions = "icacls $homedrive/$homepath/.julia/artifacts /q /c /t /reset;exit 0"
install-pre-commit = "pre-commit install"
install-ci = { depends_on = [
"reset-artifact-permissions",
"install-julia",
"update-registry-julia",
] }
# Note that this has a Windows specific override
install-ci = { depends_on = ["install-julia", "update-registry-julia"] }
install = { depends_on = [
"install-ci",
"install-qgis-plugins",
Expand Down Expand Up @@ -94,7 +88,7 @@ test-ribasim-core = { cmd = "julia --project=core --eval 'using Pkg; Pkg.test()'
test-ribasim-core-cov = { cmd = "julia --project=core --eval 'using Pkg; Pkg.test(coverage=true, julia_args=[\"--check-bounds=yes\"])'", depends_on = [
"generate-testmodels",
] }
test-ribasim-regression ={ cmd = "julia --project=core --eval 'using Pkg; Pkg.test(julia_args=[\"--check-bounds=yes\"], test_args=[\"regression\"])'", depends_on = [
test-ribasim-regression = { cmd = "julia --project=core --eval 'using Pkg; Pkg.test(julia_args=[\"--check-bounds=yes\"], test_args=[\"regression\"])'", depends_on = [
"generate-testmodels",
] }
generate-testmodels = { cmd = "python utils/generate-testmodels.py", inputs = [
Expand All @@ -115,7 +109,7 @@ codegen = { cmd = "julia --project utils/gen_python.jl && ruff format python/rib
"python/ribasim/ribasim/schemas.py",
] }
# Publish
add-ribasim-icon ={ cmd = "rcedit build/ribasim/ribasim.exe --set-icon docs/assets/ribasim.ico"}
add-ribasim-icon = { cmd = "rcedit build/ribasim/ribasim.exe --set-icon docs/assets/ribasim.ico" }
build-ribasim-python-wheel = { cmd = "rm --recursive --force dist && python -m build && twine check dist/*", cwd = "python/ribasim" }
build-ribasim-api-wheel = { cmd = "rm --recursive --force dist && python -m build && twine check dist/*", cwd = "python/ribasim_api" }
build-wheels = { depends_on = [
Expand Down Expand Up @@ -159,6 +153,16 @@ ribasim-core-testmodels = { cmd = "julia --project --threads=4 utils/testmodelru
# Release
github-release = "python utils/github-release.py"

[feature.dev.target.win.tasks]
# Workaround rare issue on Windows where the permissions of the artifacts directory are incorrect
# Upstream issue: https://github.com/JuliaLang/julia/issues/52272
reset-artifact-permissions = "icacls $homedrive/$homepath/.julia/artifacts /q /c /t /reset"
install-ci = { depends_on = [
"reset-artifact-permissions",
"install-julia",
"update-registry-julia",
] }

[dependencies]
geopandas = "*"
hatchling = "*"
Expand Down