Skip to content

Commit caef510

Browse files
committed
YAML files update
1 parent 4dfac5f commit caef510

File tree

18 files changed

+270
-44
lines changed

18 files changed

+270
-44
lines changed

.github/workflows/build.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ jobs:
1717
config:
1818
- { os: windows-latest, py: "3.9" }
1919
- { os: macOS-latest, py: "3.9" }
20-
- { os: ubuntu-latest, py: "3.7" }
2120
- { os: ubuntu-latest, py: "3.8" }
2221
- { os: ubuntu-latest, py: "3.9" }
2322
- { os: ubuntu-latest, py: "3.10" }
23+
- { os: ubuntu-latest, py: "3.11" }
2424

2525
env:
2626
SDKROOT: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk

cookiecutter.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,5 @@
2525
"Not open source"
2626
],
2727
"github_default_branch": ["main", "master"],
28-
"_copy_without_render": [".github/workflows/*.yml", "docs/overrides/main.html"]
28+
"_copy_without_render": ["docs/overrides/main.html"]
2929
}

mkdocs.yml

+20-3
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,33 @@ repo_url: https://github.com/giswqs/pypackage
66

77
theme:
88
palette:
9-
scheme: preference
9+
- scheme: default
10+
# primary: blue
11+
# accent: indigo
12+
toggle:
13+
icon: material/toggle-switch-off-outline
14+
name: Switch to dark mode
15+
- scheme: slate
16+
primary: indigo
17+
accent: indigo
18+
toggle:
19+
icon: material/toggle-switch
20+
name: Switch to light mode
1021
name: material
1122
icon:
1223
repo: fontawesome/brands/github
24+
logo: assets/logo.png
25+
favicon: assets/favicon.png
1326
features:
1427
- navigation.instant
28+
- navigation.tracking
29+
- navigation.top
1530
- search.highlight
16-
# - navigation.expand
17-
# - navigation.tabs
31+
- search.share
1832
custom_dir: "docs/overrides"
33+
font:
34+
text: Google Sans
35+
code: Regular
1936

2037
plugins:
2138
- search

setup.py

+1-5
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,15 @@
1414
keywords=['cookiecutter', 'template', 'package', 'mkdocs'],
1515
python_requires='>=3.7',
1616
classifiers=[
17-
'Development Status :: 4 - Beta',
18-
'Environment :: Console',
1917
'Intended Audience :: Developers',
2018
'Natural Language :: English',
2119
'License :: OSI Approved :: BSD License',
2220
'Programming Language :: Python',
2321
'Programming Language :: Python :: 3',
24-
'Programming Language :: Python :: 3.7',
2522
'Programming Language :: Python :: 3.8',
2623
'Programming Language :: Python :: 3.9',
2724
'Programming Language :: Python :: 3.10',
28-
'Programming Language :: Python :: Implementation :: CPython',
29-
'Programming Language :: Python :: Implementation :: PyPy',
25+
'Programming Language :: Python :: 3.11',
3026
'Topic :: Software Development',
3127
],
3228
)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: docs-build
2+
on:
3+
pull_request:
4+
branches:
5+
- {{cookiecutter.github_default_branch}}
6+
{% raw %}
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v3
12+
with:
13+
fetch-depth: 0
14+
- uses: actions/setup-python@v4
15+
with:
16+
python-version: "3.10"
17+
- name: Install GDAL
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install --find-links=https://girder.github.io/large_image_wheels --no-cache GDAL pyproj
21+
- name: Test GDAL installation
22+
run: |
23+
python -c "from osgeo import gdal"
24+
gdalinfo --version
25+
- name: Install dependencies
26+
run: |
27+
pip install --no-cache-dir Cython
28+
pip install -r requirements.txt -r requirements_dev.txt
29+
pip install .
30+
- name: Discover typos with codespell
31+
run: codespell --skip="*.csv,*.geojson,*.json,*.js,*.html,*cff,*.pdf,./.git" --ignore-words-list="aci,acount,acounts,fallow,hart,hist,nd,ned,ois,wqs"
32+
- name: PKG-TEST
33+
run: |
34+
python -m unittest discover tests/
35+
# - name: Deploy to Netlify
36+
# uses: nwtgck/[email protected]
37+
# with:
38+
# publish-dir: "./site"
39+
# production-branch: master
40+
# github-token: ${{ secrets.GITHUB_TOKEN }}
41+
# deploy-message: "Deploy from GitHub Actions"
42+
# enable-pull-request-comment: true
43+
# enable-commit-comment: false
44+
# overwrites-pull-request-comment: true
45+
# env:
46+
# NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
47+
# NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
48+
# timeout-minutes: 10
49+
{% endraw %}

{{cookiecutter.github_repo_name}}/.github/workflows/docs.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: docs
22
on:
33
push:
44
branches:
5-
- master
5+
- {{cookiecutter.github_default_branch}}
66
jobs:
77
deploy:
88
runs-on: ubuntu-latest
@@ -19,6 +19,5 @@ jobs:
1919
- name: PKG-TEST
2020
run: |
2121
python -m unittest discover tests/
22-
- run: python -m pip install --upgrade pip
23-
- run: pip install mkdocs-material mkdocstrings mkdocstrings-python-legacy mkdocs-git-revision-date-plugin mkdocs-jupyter ipykernel
22+
- run: pip install -r requirements_docs.txt
2423
- run: mkdocs gh-deploy --force
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
on:
2+
push:
3+
branches:
4+
- {{cookiecutter.github_default_branch}}
5+
pull_request:
6+
branches:
7+
- {{cookiecutter.github_default_branch}}
8+
{% raw %}
9+
name: macOS build
10+
jobs:
11+
test-macOS:
12+
runs-on: ${{ matrix.config.os }}
13+
name: ${{ matrix.config.os }} (${{ matrix.config.py }})
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
config:
18+
- { os: macOS-latest, py: "3.10" }
19+
env:
20+
SDKROOT: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
21+
steps:
22+
- name: CHECKOUT CODE
23+
uses: actions/checkout@v3
24+
- name: SETUP PYTHON
25+
uses: actions/setup-python@v4
26+
with:
27+
python-version: ${{ matrix.config.py }}
28+
# - name: Install GDAL
29+
# run: |
30+
# python -m pip install --upgrade pip
31+
# pip install --no-cache-dir Cython
32+
# pip install --find-links=https://girder.github.io/large_image_wheels --no-cache GDAL
33+
# - name: Test GDAL installation
34+
# run: |
35+
# python -c "from osgeo import gdal"
36+
# gdalinfo --version
37+
- name: Install dependencies
38+
run: |
39+
python -m pip install --upgrade pip
40+
pip install --no-cache-dir Cython
41+
pip install codespell -r requirements.txt
42+
pip install .
43+
{% endraw %}

{{cookiecutter.github_repo_name}}/.github/workflows/pypi.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# This workflows will upload a Python Package using Twine when a release is created
22
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3-
3+
{% raw %}
44
name: pypi
55

66
on:
@@ -28,3 +28,4 @@ jobs:
2828
run: |
2929
python setup.py sdist bdist_wheel
3030
twine upload dist/*
31+
{% endraw %}
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
on:
22
push:
33
branches:
4-
- master
4+
- "{{cookiecutter.github_default_branch}}"
55
pull_request:
66
branches:
7-
- master
8-
9-
name: build
7+
- "{{cookiecutter.github_default_branch}}"
8+
{% raw %}
9+
name: Linux build
1010
jobs:
1111
py-check:
1212
runs-on: ${{ matrix.config.os }}
@@ -15,28 +15,31 @@ jobs:
1515
fail-fast: false
1616
matrix:
1717
config:
18-
- { os: windows-latest, py: "3.9" }
19-
- { os: macOS-latest, py: "3.9" }
20-
- { os: ubuntu-latest, py: "3.7" }
2118
- { os: ubuntu-latest, py: "3.8" }
2219
- { os: ubuntu-latest, py: "3.9" }
2320
- { os: ubuntu-latest, py: "3.10" }
24-
25-
env:
26-
SDKROOT: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
21+
- { os: ubuntu-latest, py: "3.11" }
2722
steps:
28-
- name: CHECKOUT CODE
23+
- name: Checkout Code
2924
uses: actions/checkout@v3
30-
- name: SETUP PYTHON
25+
- name: Setup Python
3126
uses: actions/setup-python@v4
3227
with:
3328
python-version: ${{ matrix.config.py }}
34-
- name: Install dependencies
29+
- name: Install GDAL
3530
run: |
3631
python -m pip install --upgrade pip
37-
pip install --user --no-cache-dir Cython
32+
pip install --no-cache-dir Cython
33+
pip install --find-links=https://girder.github.io/large_image_wheels --no-cache GDAL
34+
- name: Test GDAL installation
35+
run: |
36+
python -c "from osgeo import gdal"
37+
gdalinfo --version
38+
- name: Install dependencies
39+
run: |
3840
pip install --user -r requirements.txt
3941
pip install --user -r requirements_dev.txt
4042
- name: PKG-TEST
4143
run: |
4244
python -m unittest discover tests/
45+
{% endraw %}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
on:
2+
push:
3+
branches:
4+
- {{cookiecutter.github_default_branch}}
5+
pull_request:
6+
branches:
7+
- {{cookiecutter.github_default_branch}}
8+
9+
name: Windows build
10+
jobs:
11+
test-windows:
12+
runs-on: windows-latest
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Install miniconda
16+
uses: conda-incubator/setup-miniconda@v2
17+
with:
18+
auto-activate-base: true
19+
python-version: "3.10"
20+
- name: Install GDAL
21+
run: conda install -c conda-forge gdal=3.4.0 --yes
22+
- name: Test GDAL installation
23+
run: |
24+
python -c "from osgeo import gdal"
25+
gdalinfo --version
26+
- name: Install dependencies
27+
run: |
28+
python -m pip install --upgrade pip
29+
pip install --no-cache-dir Cython
30+
pip install -r requirements.txt
31+
pip install .
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# common module
2+
3+
::: {{ cookiecutter.project_slug }}.common
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "code",
5+
"execution_count": null,
6+
"metadata": {},
7+
"outputs": [],
8+
"source": [
9+
"print('Hello World!')"
10+
]
11+
}
12+
],
13+
"metadata": {
14+
"language_info": {
15+
"name": "python"
16+
},
17+
"orig_nbformat": 4
18+
},
19+
"nbformat": 4,
20+
"nbformat_minor": 2
21+
}

{{cookiecutter.github_repo_name}}/docs/installation.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,8 @@ If you don't have [pip](https://pip.pypa.io) installed, this [Python installatio
1414

1515
## From sources
1616

17-
The sources for {{ cookiecutter.project_name }} can be downloaded from the Github repo.
18-
19-
You can clone the public repository:
17+
To install {{ cookiecutter.project_name }} from sources, run this command in your terminal:
2018

2119
```
22-
git clone git://github.com/{{ cookiecutter.github_username }}/{{ cookiecutter.github_repo_name }}
20+
pip install git+https://github.com/{{ cookiecutter.github_username }}/{{ cookiecutter.github_repo_name }}
2321
```

0 commit comments

Comments
 (0)