-
-
Notifications
You must be signed in to change notification settings - Fork 377
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update GitHub Actions * Update docs-build * Update docs-build * Update CI * Update CI * Pin GDAL version * Update CI * activate conda env * conda init * Add bash * Add bash * Add bash * Add checkout * Update workflows * Update ubuntu and windows * Update workflows * Update windows * Fix data error * Update notebook GitHub URL
- Loading branch information
Showing
26 changed files
with
238 additions
and
161 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,84 @@ | ||
name: docs-build | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
deploy: | ||
docs-build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ["3.10"] | ||
|
||
defaults: | ||
run: | ||
shell: bash -el {0} | ||
|
||
env: | ||
PLANET_API_KEY: ${{ secrets.PLANET_API_KEY }} | ||
USE_FOLIUM: ${{ secrets.USE_FOLIUM }} | ||
USE_MKDOCS: ${{ secrets.USE_MKDOCS }} | ||
HEREMAPS_API_KEY: ${{ secrets.HEREMAPS_API_KEY }} | ||
DP_TOKEN: ${{ secrets.DP_TOKEN }} | ||
MAPBOX_TOKEN: ${{ secrets.MAPBOX_TOKEN }} | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
GOOGLE_MAPS_API_KEY: ${{ secrets.GOOGLE_MAPS_API_KEY }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup Python | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-python@v4 | ||
auto-activate-base: true | ||
python-version: ${{ matrix.python-version }} | ||
channels: conda-forge,defaults | ||
channel-priority: true | ||
miniconda-version: latest | ||
|
||
- name: Cache dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
python-version: "3.10" | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements*.txt') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
- name: Testing conda | ||
run: | | ||
conda info | ||
conda list | ||
- name: Install GDAL | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install --find-links=https://girder.github.io/large_image_wheels --no-cache GDAL pyproj | ||
conda install -c conda-forge mamba --yes | ||
mamba install -c conda-forge gdal pyproj --yes | ||
- name: Test GDAL installation | ||
run: | | ||
python -c "from osgeo import gdal" | ||
gdalinfo --version | ||
- name: Install dependencies | ||
run: | | ||
pip install --no-cache-dir Cython PyYAML==6.0.1 | ||
pip install -r requirements.txt -r requirements_dev.txt | ||
pip install . | ||
- name: Discover typos with codespell | ||
run: codespell --skip="*.csv,*.geojson,*.json,*.js,*.html,*cff,*.pdf" --ignore-words-list="aci,acount,acounts,fallow,hart,hist,nd,ned,ois,wqs" | ||
run: codespell --skip=".*,.git/*,*.csv,*.geojson,*.json,*.js,*.html,*cff,*.pdf" --ignore-words-list="aci,acount,acounts,fallow,hart,hist,nd,ned,ois,wqs" | ||
|
||
- name: PKG-TEST | ||
run: python -m unittest discover tests/ | ||
|
||
- name: Install mkdocs | ||
run: | | ||
python -m unittest discover tests/ | ||
env: | ||
PLANET_API_KEY: ${{ secrets.PLANET_API_KEY }} | ||
- run: pip install -r requirements_docs.txt | ||
- run: mkdocs build | ||
env: | ||
USE_FOLIUM: ${{ secrets.USE_FOLIUM }} | ||
USE_MKDOCS: ${{ secrets.USE_MKDOCS }} | ||
HEREMAPS_API_KEY: ${{ secrets.HEREMAPS_API_KEY }} | ||
DP_TOKEN: ${{ secrets.DP_TOKEN }} | ||
PLANET_API_KEY: ${{ secrets.PLANET_API_KEY }} | ||
MAPBOX_TOKEN: ${{ secrets.MAPBOX_TOKEN }} | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
GOOGLE_MAPS_API_KEY: ${{ secrets.GOOGLE_MAPS_API_KEY }} | ||
pip install -r requirements_docs.txt | ||
mkdocs build | ||
- name: Deploy to Netlify | ||
uses: nwtgck/[email protected] | ||
with: | ||
|
@@ -58,4 +92,8 @@ jobs: | |
env: | ||
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} | ||
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} | ||
timeout-minutes: 10 | ||
|
||
- name: Cleanup | ||
if: always() | ||
run: | | ||
echo "Cleaning up resources." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.