Skip to content

wip: add clip by bbox #21

wip: add clip by bbox

wip: add clip by bbox #21

Workflow file for this run

name: CI
on:
push:
branches:
- main
paths-ignore:
- "requirements.txt"
- "requirements.dev.txt"
pull_request:
branches:
- main
jobs:
ci:
if: ${{ github.repository == 'HideBa/ahn_cli' }}
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.11.1
- name: Install PDAL
run: |
sudo apt-get update
sudo apt-get install -y \
g++ \
cmake \
git \
libgdal-dev \
libgeotiff-dev \
liblaszip-dev \
libboost-all-dev \
libboost-program-options-dev \
libboost-filesystem-dev \
libboost-system-dev \
libsqlite3-dev \
sqlite3 \
libproj-dev \
libcurl4-openssl-dev \
libjsoncpp-dev \
libxml2-dev \
libflann-dev \
libpcl-dev \
libeigen3-dev \
libnitro-dev \
libqhull-dev \
libtbb-dev
- name: Clone PDAL
run: |
git clone https://github.com/PDAL/PDAL.git
cd PDAL
git checkout 2.5-maintenance
mkdir build
cd build
cmake ..
make
sudo make install
sudo ldconfig
pdal --version
- name: Check pdal
run: |
echo "PDAL version -------------"
pdal --version
- name: Cache pip packages
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-poetry-${{ hashFiles('poetry.lock') }}
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
- name: Configure Poetry
run: |
poetry config virtualenvs.create false
- name: Install dependencies
run: |
poetry install
# - name: Install dependencies excluding PDAL
# run: |
# poetry add pdal --optional
# poetry install --no-root
# - name: Install PDAL Python package
# run: |
# source .venv/bin/activate
# pip install pdal==3.2.3
- name: Linting
run: |
poetry run pylint ./ahn_cli/**/*.py
- name: Type checking
run: |
poetry run mypy ./ahn_cli/**/*.py
- name: Testing
run: poetry run pytest ./ahn_cli/**/*.py --cov=./ahn_cli
- name: Export requirements
run: |
poetry export --dev --format requirements.txt --output requirements.txt
poetry export --dev --format requirements.txt --output requirements.dev.txt
- name: Commit exported requirements
run: |
git config --global user.name "${{ secrets.GH_USER_NAME }}"
git config --global user.email "${{ secrets.GH_USER_EMAIL }}"
git add requirements.txt requirements.dev.txt
git commit -m "Update requirements"
git push origin main