Skip to content

Commit 34633b2

Browse files
authored
Merge pull request #235 from InsightSoftwareConsortium/new-black-linter
2 parents 66453fd + 57e2409 commit 34633b2

File tree

4 files changed

+25
-71
lines changed

4 files changed

+25
-71
lines changed

.github/workflows/build-test-publish.yml

Lines changed: 16 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,17 @@ jobs:
1313
- os: ubuntu-18.04
1414
c-compiler: "gcc"
1515
cxx-compiler: "g++"
16-
itk-git-tag: "v5.2rc03"
16+
itk-git-tag: "3f6c15eb531cecbd7de1b5ddd8667d5978493344"
1717
cmake-build-type: "MinSizeRel"
1818
- os: windows-2019
1919
c-compiler: "cl.exe"
2020
cxx-compiler: "cl.exe"
21-
itk-git-tag: "v5.2rc03"
21+
itk-git-tag: "3f6c15eb531cecbd7de1b5ddd8667d5978493344"
2222
cmake-build-type: "Release"
2323
- os: macos-10.15
2424
c-compiler: "clang"
2525
cxx-compiler: "clang++"
26-
itk-git-tag: "v5.2rc03"
26+
itk-git-tag: "3f6c15eb531cecbd7de1b5ddd8667d5978493344"
2727
cmake-build-type: "MinSizeRel"
2828

2929
steps:
@@ -77,9 +77,9 @@ jobs:
7777
operating_system="${{ matrix.os }}"
7878
cat > dashboard.cmake << EOF
7979
set(CTEST_SITE "GitHubActions")
80-
file(TO_CMAKE_PATH "${GITHUB_WORKSPACE}/.." CTEST_DASHBOARD_ROOT)
81-
file(TO_CMAKE_PATH "${GITHUB_WORKSPACE}/" CTEST_SOURCE_DIRECTORY)
82-
file(TO_CMAKE_PATH "${GITHUB_WORKSPACE}/../build" CTEST_BINARY_DIRECTORY)
80+
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/.." CTEST_DASHBOARD_ROOT)
81+
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/" CTEST_SOURCE_DIRECTORY)
82+
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../build" CTEST_BINARY_DIRECTORY)
8383
set(dashboard_source_name "${GITHUB_REPOSITORY}")
8484
if(ENV{GITHUB_REF} MATCHES "master")
8585
set(branch "-master")
@@ -122,7 +122,7 @@ jobs:
122122
ctest -j 2 -VV -S dashboard.cmake
123123
shell: cmd
124124

125-
build-test-python:
125+
build-test-superbuild:
126126
runs-on: ${{ matrix.os }}
127127
strategy:
128128
max-parallel: 3
@@ -132,21 +132,20 @@ jobs:
132132
- os: ubuntu-18.04
133133
c-compiler: "gcc"
134134
cxx-compiler: "g++"
135-
itk-git-tag: "v5.2rc03"
136135
cmake-build-type: "MinSizeRel"
137136
- os: windows-2019
138137
c-compiler: "cl.exe"
139138
cxx-compiler: "cl.exe"
140-
itk-git-tag: "v5.2rc03"
141139
cmake-build-type: "Release"
142140
- os: macos-10.15
143141
c-compiler: "clang"
144142
cxx-compiler: "clang++"
145-
itk-git-tag: "v5.2rc03"
146143
cmake-build-type: "MinSizeRel"
147144

148145
steps:
149-
- uses: actions/checkout@v1
146+
- uses: actions/checkout@v2
147+
with:
148+
path: Ex
150149

151150
- name: Set up Python 3.7
152151
uses: actions/setup-python@v1
@@ -157,52 +156,25 @@ jobs:
157156
run: |
158157
python -m pip install --upgrade pip
159158
python -m pip install ninja
160-
python -m pip install itk==5.2rc03
161159
162160
- name: Get specific version of CMake, Ninja
163161
uses: lukka/get-cmake@v3.18.3
164162

165-
- name: Download ITK
166-
run: |
167-
cd ..
168-
git clone https://github.com/InsightSoftwareConsortium/ITK.git
169-
cd ITK
170-
git checkout ${{ matrix.itk-git-tag }}
171-
172-
- name: Build ITK
173-
if: matrix.os != 'windows-2019'
174-
run: |
175-
cd ..
176-
mkdir ITK-build
177-
cd ITK-build
178-
cmake -DCMAKE_C_COMPILER:FILEPATH="${{ matrix.c-compiler }}" -DBUILD_SHARED_LIBS:BOOL=ON -DCMAKE_CXX_COMPILER="${{ matrix.cxx-compiler }}" -DCMAKE_BUILD_TYPE:STRING=${{ matrix.cmake-build-type }} -DBUILD_TESTING:BOOL=OFF -GNinja ../ITK
179-
ninja
180-
181-
- name: Build ITK
182-
if: matrix.os == 'windows-2019'
183-
run: |
184-
cd ..
185-
mkdir ITK-build
186-
cd ITK-build
187-
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
188-
cmake -DCMAKE_C_COMPILER:FILEPATH="${{ matrix.c-compiler }}" -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_CXX_COMPILER="${{ matrix.cxx-compiler }}" -DCMAKE_BUILD_TYPE:STRING=${{ matrix.cmake-build-type }} -DBUILD_TESTING:BOOL=OFF -GNinja ../ITK
189-
ninja
190-
shell: cmd
191-
192163
- name: Fetch CTest driver script
193164
run: |
194-
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITK/dashboard/itk_common.cmake -O
165+
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKExamples/dashboard/itkexamples_common.cmake -O
195166
196167
- name: Configure CTest script
197168
shell: bash
198169
run: |
170+
mv Ex ../../
199171
operating_system="${{ matrix.os }}"
200172
cat > dashboard.cmake << EOF
201173
set(CTEST_SITE "GitHubActions")
202174
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/.." CTEST_DASHBOARD_ROOT)
203-
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/" CTEST_SOURCE_DIRECTORY)
204-
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../build" CTEST_BINARY_DIRECTORY)
205-
set(dashboard_source_name "${GITHUB_REPOSITORY}")
175+
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../../Ex" CTEST_SOURCE_DIRECTORY)
176+
file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../../bld/" CTEST_BINARY_DIRECTORY)
177+
set(dashboard_superbuild 1)
206178
if(ENV{GITHUB_REF} MATCHES "master")
207179
set(branch "-master")
208180
set(dashboard_model "Continuous")
@@ -227,14 +199,12 @@ jobs:
227199
set(ENV{PATH} "\${CTEST_DASHBOARD_ROOT}/ITK-build/bin;\$ENV{PATH}")
228200
endif()
229201
set(dashboard_cache "
230-
ITK_DIR:PATH=\${CTEST_DASHBOARD_ROOT}/ITK-build
231202
BUILD_TESTING:BOOL=ON
232-
ITK_WRAP_PYTHON:BOOL=ON
233203
")
234204
string(TIMESTAMP build_date "%Y-%m-%d")
235205
message("CDash Build Identifier: \${build_date} \${CTEST_BUILD_NAME}")
236206
message("CTEST_SITE = \${CTEST_SITE}")
237-
include(\${CTEST_SCRIPT_DIRECTORY}/itk_common.cmake)
207+
include(\${CTEST_SCRIPT_DIRECTORY}/itkexamples_common.cmake)
238208
EOF
239209
cat dashboard.cmake
240210
@@ -256,22 +226,6 @@ jobs:
256226
max-parallel: 3
257227
matrix:
258228
os: [ubuntu-18.04, windows-2019, macos-10.15]
259-
include:
260-
- os: ubuntu-18.04
261-
c-compiler: "gcc"
262-
cxx-compiler: "g++"
263-
itk-git-tag: "v5.2rc03"
264-
cmake-build-type: "MinSizeRel"
265-
- os: windows-2019
266-
c-compiler: "cl.exe"
267-
cxx-compiler: "cl.exe"
268-
itk-git-tag: "v5.2rc03"
269-
cmake-build-type: "Release"
270-
- os: macos-10.15
271-
c-compiler: "clang"
272-
cxx-compiler: "clang++"
273-
itk-git-tag: "v5.2rc03"
274-
cmake-build-type: "MinSizeRel"
275229

276230
steps:
277231
- uses: actions/checkout@v1

.github/workflows/lint.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ jobs:
1717
with:
1818
python-version: 3.9
1919

20-
- name: Install Python dependencies
21-
run: pip install black
22-
2320
- name: Lint Python
24-
uses: wearerequired/lint-action@v1
25-
with:
26-
black: true
27-
black_dir: src/
21+
uses: github/super-linter@v3
22+
env:
23+
VALIDATE_ALL_CODEBASE: false
24+
VALIDATE_PYTHON_BLACK: true
25+
VALIDATE_YAML: true
26+
DEFAULT_BRANCH: master
27+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ endif()
8080
if(NOT ITK_VERSION)
8181
# To get the ITK version information from external package when building
8282
# stand alone, ITK is required.
83-
find_package(ITK 5.1.0 REQUIRED)
83+
find_package(ITK 5.2.0 REQUIRED)
8484
endif()
8585
set(ITKExamples_VERSION_MAJOR ${ITK_VERSION_MAJOR})
8686
set(ITKExamples_VERSION_MINOR ${ITK_VERSION_MINOR})

Superbuild/External-ITK.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Get and build itk
33

44
if(NOT ITK_TAG)
5-
set(ITK_TAG "v5.2rc03")
5+
set(ITK_TAG "3f6c15eb531cecbd7de1b5ddd8667d5978493344")
66
endif()
77

88
set(_vtk_args)

0 commit comments

Comments
 (0)