Skip to content

Commit

Permalink
Add Conda CI
Browse files Browse the repository at this point in the history
  • Loading branch information
lamyj committed Apr 14, 2024
1 parent b94f558 commit 2124726
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 47 deletions.
8 changes: 8 additions & 0 deletions .ci/build/conda.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import subprocess
import sys

conda = sys.argv[1] if len(sys.argv) >= 2 else "conda"

subprocess.check_call([
conda, "install", "--yes", "-c", "conda-forge",
"boost", "cmake", "dcmtk", "icu", "jsoncpp", "ninja", "pybind11"])
9 changes: 4 additions & 5 deletions .ci/build/post_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@
os.environ["PYTHONPATH"] = os.pathsep.join([
*os.environ.get("PYTHONPATH", "").split(os.pathsep), python_lib_dir])

os.environ |= {
"ODIL_OWN_AET": "LOCAL",
"ODIL_PEER_HOST_NAME": "127.0.0.1",
"ODIL_PEER_PORT": "11112",
"ODIL_PEER_AET": "REMOTE"}
os.environ["ODIL_OWN_AET"] = "LOCAL"
os.environ["ODIL_PEER_HOST_NAME"] = "127.0.0.1"
os.environ["ODIL_PEER_PORT"] = "11112"
os.environ["ODIL_PEER_AET"] = "REMOTE"
os.environ["PATH"] = os.pathsep.join([
*os.environ["PATH"].split(os.pathsep),
os.path.join(workspace, "tests/tools")])
Expand Down
38 changes: 0 additions & 38 deletions .ci/deb/post_build

This file was deleted.

20 changes: 16 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,20 @@ jobs:
fail-fast: false
matrix:
include:
- { os: "ubuntu-latest", container: "debian:bullseye", packaging: "apt", python: "python3" }
- { os: "ubuntu-latest", container: "debian:bookworm", packaging: "apt", cmake_options: "-DCMAKE_CXX_STANDARD=17", python: "python3" }
- { os: "ubuntu-latest", container: "ubuntu:focal", packaging: "apt", python: "python3" }
- { os: "ubuntu-latest", container: "ubuntu:jammy", packaging: "apt", cmake_options: "-DCMAKE_CXX_STANDARD=17", python: "python3" }
- { os: "ubuntu-latest", container: "debian:bullseye", packaging: "apt", python: "python3" }
- { os: "ubuntu-latest", container: "debian:bookworm", packaging: "apt", cmake_options: "-DCMAKE_CXX_STANDARD=17", python: "python3" }
- { os: "ubuntu-latest", container: "ubuntu:focal", packaging: "apt", python: "python3" }
- { os: "ubuntu-latest", container: "ubuntu:jammy", packaging: "apt", cmake_options: "-DCMAKE_CXX_STANDARD=17", python: "python3" }
- { os: "ubuntu-latest", packaging: "conda", cmake_options: "-DCMAKE_CXX_STANDARD=17", python: "python" }
# - name: "macOS 11 (Big Sur) + Homebrew"
# os: macos-11
# ci_type: brew
env:
WORKSPACE: "${{ github.workspace }}"
CMAKE_OPTIONS: "${{ matrix.cmake_options }}"
defaults:
run:
shell: ${{ contains(matrix.os, 'windows') && 'pwsh' || 'bash -l {0}' }}
steps:
- name: Provision (Debian, Ubuntu)
# Install Python and Git. macOS workers already have this, however for
Expand All @@ -29,6 +33,14 @@ jobs:
DEBIAN_FRONTEND=noninteractive apt-get install -y git python3
if: ${{ contains(matrix.packaging, 'apt') }}

- name: Provision (Micromamba)
uses: mamba-org/setup-micromamba@v1
with:
init-shell: bash powershell
environment-name: dicomifier
create-args: python=3.11
if: ${{ contains(matrix.packaging, 'conda') }}

- name: Checkout latest revision
uses: actions/checkout@v4

Expand Down

0 comments on commit 2124726

Please sign in to comment.