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

Ci health #327

Merged
merged 27 commits into from
Nov 12, 2024
Merged
Show file tree
Hide file tree
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
79 changes: 79 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
name: Build

on:
push:
paths-ignore:
- 'doc/**'
pull_request:
paths-ignore:
- 'doc/**'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
build:
name: ${{ matrix.os }}

runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
os: ['ubuntu-latest', 'macos-latest', 'windows-latest']

steps:
- uses: actions/checkout@v4
- name: Support longpaths
run: git config --system core.longpaths true
if: matrix.platform == 'windows-latest'

- uses: ilammy/msvc-dev-cmd@v1
if: matrix.os == 'windows-latest'

- uses: conda-incubator/setup-miniconda@v3
with:
environment-file: "scripts/ci/environment.yml"
mamba-version: "*"
channels: conda-forge,defaults
activate-environment: "entwine-build"
channel-priority: true


- name: CMake
shell: bash -l {0}
run: |
if [ "$RUNNER_OS" == "Windows" ]; then
export CC=cl.exe
export CXX=cl.exe
export PREFIX_BASE=Library
fi
mkdir build
cd build
cmake .. \
-G Ninja \
-DCMAKE_PREFIX_PATH:FILEPATH="$CONDA_PREFIX/$PREFIX_BASE" \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DBUILD_SHARED_LIBS=ON \
-DBUILD_TESTING=ON \
-DCMAKE_INSTALL_PREFIX=${CONDA_PREFIX} \
-D_SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING=1 \
-Dgtest_force_shared_crt=ON \
..

- name: Compile
shell: bash -l {0}
run: |
ninja install
working-directory: ./build

- name: Test
shell: bash -l {0}
run: |
if [ "$RUNNER_OS" == "Windows" ]; then
export PATH="%cd%/bin:$PATH"
echo "PATHSETTING $PATH"
fi
ctest -VV --output-on-failure
working-directory: ./build

25 changes: 8 additions & 17 deletions .github/workflows/conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,41 +24,32 @@ jobs:
platform: ['ubuntu-latest','windows-latest','macos-latest']
env:
PDAL_PLATFORM: ${{ matrix.platform }}
CACHE_NUMBER: 1

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Support longpaths
run: git config --system core.longpaths true
if: matrix.platform == 'windows-latest'

- name: Cache Conda Environment
uses: actions/cache@v2
- uses: conda-incubator/setup-miniconda@v3
with:
path: ~/conda_pkgs_dir
key: ${{ runner.os }}-${{ steps.get-date.outputs.today }}-conda-${{ env.CACHE_NUMBER }}

- uses: conda-incubator/setup-miniconda@v2
with:
miniforge-variant: Mambaforge
miniforge-version: latest
use-mamba: true
auto-update-conda: true
use-only-tar-bz2: false
channels: conda-forge
environment-file: "scripts/ci/environment.yml"
environment-name: "entwine-build"

- name: Setup
shell: bash -l {0}
shell: bash -el {0}
run: |
source ./scripts/ci/conda/setup.sh

- name: Build
shell: bash -l {0}
shell: bash -el {0}
run: |
source ../scripts/ci/conda/compile.sh
working-directory: ./entwine-feedstock

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.platform }}-conda-package
path: ./entwine-feedstock/packages/
12 changes: 6 additions & 6 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,28 @@ jobs:
PUSH_PACKAGES: ${{ github.repository_owner == 'connormanning' && github.event_name != 'pull_request' }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Setup Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
with:
version: latest
- if: ${{ env.PUSH_PACKAGES == 'true' }}
name: Login to GitHub Container Registry
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GHCR_TOKEN }}
- if: ${{ env.PUSH_PACKAGES == 'true' }}
name: Login to Docker Hub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
with:
buildkitd-flags: --debug
- name: Prepare
Expand All @@ -45,7 +45,7 @@ jobs:
echo ::set-output name=BUILD_DATE::$(date -u +'%Y-%m-%dT%H:%M:%SZ')
echo ::set-output name=VERSION::${VERSION}
- name: Build image
uses: docker/build-push-action@v4
uses: docker/build-push-action@v6
with:
push: ${{ env.PUSH_PACKAGES == 'true' }}
builder: ${{ steps.buildx.outputs.name }}
Expand Down
54 changes: 0 additions & 54 deletions .github/workflows/docs.yml

This file was deleted.

71 changes: 0 additions & 71 deletions .github/workflows/linux.yml

This file was deleted.

70 changes: 0 additions & 70 deletions .github/workflows/osx.yml

This file was deleted.

Loading
Loading