Skip to content

Commit 10098e6

Browse files
authored
Merge branch 'main' into check-against-latest
2 parents 681a306 + c6e7ee3 commit 10098e6

File tree

4 files changed

+56
-4
lines changed

4 files changed

+56
-4
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Read the Docs PR preview
2+
# Automatically edits a pull request's descriptions with a link
3+
# to the documentation's preview on Read the Docs.
4+
5+
on:
6+
pull_request_target:
7+
types:
8+
- opened
9+
10+
permissions:
11+
pull-requests: write
12+
13+
concurrency:
14+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
15+
cancel-in-progress: true
16+
17+
jobs:
18+
documentation-links:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: readthedocs/actions/preview@v1
22+
with:
23+
project-slug: "pydocs-translation-dashboard"
24+
single-version: "true"

.github/workflows/update.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,11 @@ jobs:
1212
permissions:
1313
contents: write
1414
steps:
15-
- uses: actions/setup-python@main
16-
- uses: astral-sh/setup-uv@main
17-
- uses: actions/checkout@main
15+
- uses: actions/setup-python@v5
16+
with:
17+
python-version: "3.x"
18+
- uses: astral-sh/setup-uv@v4
19+
- uses: actions/checkout@v4
1820
- run: sudo apt-get install -y gettext
1921
- run: uv run generate.py # generates "index.html"
2022
- run: mkdir -p build && cp index.html style.css build
@@ -30,3 +32,7 @@ jobs:
3032
curl -Lo index.html-public https://github.com/m-aciek/pydocs-translation-dashboard/raw/refs/heads/gh-pages/index.html
3133
diff --color=always -u index.html-public index.html || :
3234
cat index.html
35+
- uses: actions/upload-artifact@v4
36+
with:
37+
name: build
38+
path: build

.readthedocs.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Read the Docs configuration file
2+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
3+
# Project page: https://app.readthedocs.org/projects/pydocs-translation-dashboard/
4+
5+
version: 2
6+
7+
build:
8+
os: ubuntu-24.04
9+
tools:
10+
python: "3"
11+
commands:
12+
- asdf plugin add uv
13+
- asdf install uv latest
14+
- asdf global uv latest
15+
- uv run generate.py
16+
- mkdir -p _readthedocs/html
17+
- mv index.html style.css _readthedocs/html

generate.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,11 @@
5656
<tbody>
5757
{% for language, completion in completion_progress | sort(attribute=1) | reverse %}
5858
<tr>
59-
<td data-label="language">{{ language }}</td>
59+
<td data-label="language">
60+
<a href="https://github.com/python/python-docs-{{ language }}" target="_blank">
61+
{{ language }}
62+
</a>
63+
</td>
6064
<td data-label="completion">
6165
<div class="progress-bar" style="width: {{ completion | round(2) }}%;">{{ completion | round(2) }}%</div>
6266
</td>
@@ -65,6 +69,7 @@
6569
</tbody>
6670
</table>
6771
<p>Last updated at {{ generation_time.strftime('%A, %d %B %Y, %X %Z') }}.</p>
72+
<p>Note that the completion value is based on files available in language Git repository and <a href="https://github.com/m-aciek/pydocs-translation-dashboard/issues/2" target="_blank">may not include</a> e.g. resources which translation hasn't yet started.</p>
6873
</body>
6974
</html>""")
7075

0 commit comments

Comments
 (0)