-
Notifications
You must be signed in to change notification settings - Fork 3
54 lines (54 loc) · 2 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: CI
on: push
jobs:
build:
runs-on: ubuntu-latest
env:
paraview_version: 5.9.1
paraview_name: ParaView-5.9.1-MPI-Linux-Python3.8-64bit
steps:
- uses: actions/checkout@v2
- name: Docker
run: |
docker pull lhofmann/paraview-superbuild:${paraview_version}
docker run -itd \
--user "$(id -u ${USER}):$(id -g ${USER})" \
--name build \
--volume="${GITHUB_WORKSPACE}:/mnt/shared:ro" \
lhofmann/paraview-superbuild:${paraview_version}
- name: Install GraphViz
run: |
docker exec --user=root:root build \
/bin/bash /mnt/shared/.github/workflows/install_graphviz.sh
- name: Configure
run: |
docker exec build /usr/bin/scl enable devtoolset-8 -- cmake \
-B/tmp/superbuild \
-H/mnt/shared/ \
-DMili_INCLUDE_DIR=/home/paraview/buildbuildbuildbuildbuildbuildbuildbuildbuildbuildbuildbuildbuildbuild/install/include \
-DCMAKE_INSTALL_PREFIX=/tmp/package/${paraview_name} \
-DCMAKE_INSTALL_LIBDIR=lib
- name: Build
run: docker exec build cmake --build /tmp/superbuild --target install
- name: Package
run: |
docker exec build /bin/bash -c "cd /tmp/package; tar czf ${paraview_name}.tar.gz ${paraview_name}/"
mkdir package
pushd package
docker cp "build:/tmp/package/${paraview_name}.tar.gz" .
tar xf ${paraview_name}.tar.gz
mv ${paraview_name}.tar.gz ../
popd
- uses: actions/upload-artifact@v2
with:
name: ParaView-5.9.1-MPI-Linux-Python3.8-64bit
path: ./package/
- name: Prepare release
run: mv ${paraview_name}.tar.gz NetworkEditor-PV${paraview_version}-${GITHUB_REF##*/}.tar.gz
if: startsWith(github.ref, 'refs/tags/')
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
fail_on_unmatched_files: True
files: "*.tar.gz"