Skip to content

Commit 51ca397

Browse files
authored
Merge pull request #63 from python-project-templates/tkp/yardang
Add yardang option, fixes #57
2 parents 42057e0 + 2137b4f commit 51ca397

17 files changed

+147
-8
lines changed

copier.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,8 @@ python_version_primary:
6565
"3.12":
6666
value: "3.12"
6767
help: Primary version of Python to use in CI/CD
68+
69+
add_docs:
70+
type: bool
71+
default: false
72+
help: Add documentation using Yardang/Sphinx
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Docs
2+
on:
3+
push:
4+
branches:
5+
- main
6+
workflow_dispatch:
7+
permissions:
8+
contents: write
9+
jobs:
10+
docs:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: actions-ext/python/setup@main
15+
- uses: actions-ext/node/setup@main
16+
- run: uv pip install .
17+
- run: uv pip install yardang
18+
- run: yardang build
19+
- uses: peaceiris/actions-gh-pages@v4
20+
with:
21+
publish_branch: gh-pages
22+
github_token: {% raw %}${{ secrets.GITHUB_TOKEN }}{% endraw %}
23+
publish_dir: docs/html

cpp/.gitignore.jinja

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,9 @@ dmypy.json
129129
.pyre/
130130

131131
# Documentation
132-
docs/_build/
133132
/site
133+
index.md
134+
docs/_build/
134135
docs/api
135136
docs/index.md
136137
docs/html

examples/cpp.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
2-
add_extension: cpp
2+
add_docs: true
3+
add_extension: cpp
34
email: 3105306+timkpaine@users.noreply.github.com
45
github: python-project-templates
56
project_description: A C++-Python project template

examples/js.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
2-
add_extension: js
2+
add_docs: true
3+
add_extension: js
34
email: 3105306+timkpaine@users.noreply.github.com
45
github: python-project-templates
56
project_description: A JavaScript-Python project template

examples/jupyter.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
---
2+
add_docs: true
23
add_extension: jupyter
34
email: 3105306+timkpaine@users.noreply.github.com
45
github: python-project-templates

examples/python.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
---
2+
add_docs: true
23
add_extension: python
34
email: 3105306+timkpaine@users.noreply.github.com
45
github: python-project-templates

examples/rust.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
---
2+
add_docs: true
23
add_extension: rust
34
email: 3105306+timkpaine@users.noreply.github.com
45
github: python-project-templates
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Docs
2+
on:
3+
push:
4+
branches:
5+
- main
6+
workflow_dispatch:
7+
permissions:
8+
contents: write
9+
jobs:
10+
docs:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: actions-ext/python/setup@main
15+
- uses: actions-ext/node/setup@main
16+
- run: uv pip install .
17+
- run: uv pip install yardang
18+
- run: yardang build
19+
- uses: peaceiris/actions-gh-pages@v4
20+
with:
21+
publish_branch: gh-pages
22+
github_token: {% raw %}${{ secrets.GITHUB_TOKEN }}{% endraw %}
23+
publish_dir: docs/html

js/.gitignore.jinja

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,9 @@ dmypy.json
125125
.pyre/
126126

127127
# Documentation
128-
docs/_build/
129128
/site
129+
index.md
130+
docs/_build/
130131
docs/api
131132
docs/index.md
132133
docs/html

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy