From bec32f3b6d9bdb0bab559b3a52a8afd0d3ab574b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=20Haitz=20Legarreta=20Gorro=C3=B1o?= Date: Sat, 7 Sep 2024 16:38:31 -0400 Subject: [PATCH] ENH: Transition CIs to GHA using ITK remote module build actions Transition CIs to GHA using ITK remote module build actions: - Add the ITK remote module build GHA workflow file. - Remove Appveyor, CircleCI and Travis CI config files. Take advantage of the commit to add the clang format linter GHA workflow file. Update the `README.rst` file badges accordingly. --- .circleci/config.yml | 63 ----------------------- .github/workflows/build-test-package.yml | 20 +++++++ .github/workflows/clang-format-linter.yml | 0 .travis.yml | 15 ------ README.rst | 18 +++---- appveyor.yml | 21 -------- 6 files changed, 26 insertions(+), 111 deletions(-) delete mode 100644 .circleci/config.yml create mode 100644 .github/workflows/build-test-package.yml create mode 100644 .github/workflows/clang-format-linter.yml delete mode 100644 .travis.yml delete mode 100644 appveyor.yml diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index 5a09c53f..00000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,63 +0,0 @@ -version: 2 -jobs: - build-and-test: - working_directory: /LesionSizingToolkit-build - docker: - - image: insighttoolkit/module-ci:latest - steps: - - checkout: - path: /LesionSizingToolkit - - run: - name: Fetch CTest driver script - command: | - curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITK/dashboard/itk_common.cmake -O - - run: - name: Configure CTest script - command: | - SHASNIP=$(echo $CIRCLE_SHA1 | cut -c1-7) - cat > dashboard.cmake << EOF - set(CTEST_SITE "CircleCI") - set(CTEST_BUILD_NAME "External-LesionSizingToolkit-${CIRCLE_BRANCH}-${CIRCLE_BUILD_NUM}-${SHASNIP}") - set(CTEST_BUILD_CONFIGURATION "MinSizeRel") - set(CTEST_CMAKE_GENERATOR "Unix Makefiles") - set(CTEST_BUILD_FLAGS: "-j5") - set(CTEST_SOURCE_DIRECTORY /LesionSizingToolkit) - set(CTEST_BINARY_DIRECTORY /LesionSizingToolkit-build) - set(dashboard_model Experimental) - set(dashboard_no_clean 1) - set(dashboard_cache " - ITK_DIR:PATH=/ITK-build - BUILD_TESTING:BOOL=ON - ") - include(\${CTEST_SCRIPT_DIRECTORY}/itk_common.cmake) - EOF - - run: - name: Build and Test - no_output_timeout: 1.0h - command: | - ctest -j 2 -VV -S dashboard.cmake - package: - working_directory: ~/LesionSizingToolkit - machine: true - steps: - - checkout - - run: - name: Fetch build script - command: | - curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKPythonPackage/master/scripts/dockcross-manylinux-download-cache-and-build-module-wheels.sh -O - chmod u+x dockcross-manylinux-download-cache-and-build-module-wheels.sh - - run: - name: Build Python packages - no_output_timeout: 1.0h - command: | - ./dockcross-manylinux-download-cache-and-build-module-wheels.sh - - store_artifacts: - path: dist - destination: dist - -workflows: - version: 2 - build-test-package: - jobs: - - build-and-test - - package diff --git a/.github/workflows/build-test-package.yml b/.github/workflows/build-test-package.yml new file mode 100644 index 00000000..c4f99406 --- /dev/null +++ b/.github/workflows/build-test-package.yml @@ -0,0 +1,20 @@ +name: Build, test, package + +on: + push: + branches: + - main + tags: + - 'v*' + pull_request: + branches: + - main + +jobs: + cxx-build-workflow: + uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-cxx.yml@v5.4.0 + + python-build-workflow: + uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-package-python.yml@v5.4.0 + secrets: + pypi_password: ${{ secrets.pypi_password }} diff --git a/.github/workflows/clang-format-linter.yml b/.github/workflows/clang-format-linter.yml new file mode 100644 index 00000000..e69de29b diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 4bd8df13..00000000 --- a/.travis.yml +++ /dev/null @@ -1,15 +0,0 @@ -sudo: true -language: cpp -os: -- osx -compiler: -- gcc -cache: - directories: - - "$HOME/Library/Caches/Homebrew" -script: -- curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKPythonPackage/master/scripts/macpython-download-cache-and-build-module-wheels.sh -O -- chmod u+x macpython-download-cache-and-build-module-wheels.sh -- ./macpython-download-cache-and-build-module-wheels.sh -- tar -zcvf dist.tar.gz dist/ -- curl --upload-file dist.tar.gz https://transfer.sh/dist.tar.gz diff --git a/README.rst b/README.rst index bf635868..c8e5b215 100644 --- a/README.rst +++ b/README.rst @@ -1,20 +1,14 @@ The Lesion Sizing Toolkit (LSTK) ================================ -.. |CircleCI| image:: https://circleci.com/gh/InsightSoftwareConsortium/LesionSizingToolkit.svg?style=shield - :target: https://circleci.com/gh/InsightSoftwareConsortium/LesionSizingToolkit +.. image:: https://github.com/InsightSoftwareConsortium/LesionSizingToolkit/actions/workflows/build-test-package.yml/badge.svg + :target: https://github.com/InsightSoftwareConsortium/LesionSizingToolkit/actions/workflows/build-test-package.yml + :alt: Build Status -.. |TravisCI| image:: https://travis-ci.org/InsightSoftwareConsortium/LesionSizingToolkit.svg?branch=master - :target: https://travis-ci.org/InsightSoftwareConsortium/LesionSizingToolkit +.. image:: https://img.shields.io/badge/License-Apache%202.0-blue.svg + :target: https://github.com/InsightSoftwareConsortium/LesionSizingToolkit/blob/master/LICENSE + :alt: License -.. |AppVeyor| image:: https://img.shields.io/appveyor/ci/InsightSoftwareConsortium/lesionsizingtoolkit.svg - :target: https://ci.appveyor.com/project/InsightSoftwareConsortium/lesionsizingtoolkit - -=========== =========== =========== - Linux macOS Windows -=========== =========== =========== -|CircleCI| |TravisCI| |AppVeyor| -=========== =========== =========== Overview -------- diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 99c62fc3..00000000 --- a/appveyor.yml +++ /dev/null @@ -1,21 +0,0 @@ -branches: - only: - - master - -version: "0.0.1.{build}" - -install: - - - curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKPythonPackage/master/scripts/windows-download-cache-and-build-module-wheels.ps1 -O - - ps: .\windows-download-cache-and-build-module-wheels.ps1 - -build: off - -test: off - -artifacts: - - # pushing entire folder as a zip archive - - path: dist\* - -deploy: off