diff --git a/.github/workflows/check_links.yml b/.github/workflows/check_links.yml index 202adee..d27c51b 100644 --- a/.github/workflows/check_links.yml +++ b/.github/workflows/check_links.yml @@ -14,7 +14,7 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v6 - name: Build documentation - run: uv run sphinx-build -nWaE . _build + run: uv run sphinx-build -nWaE docs build - name: Link Checker id: lychee uses: lycheeverse/lychee-action@v2 diff --git a/.github/workflows/generate_grants.yml b/.github/workflows/generate_grants.yml index 22abab1..01dbe7f 100644 --- a/.github/workflows/generate_grants.yml +++ b/.github/workflows/generate_grants.yml @@ -13,14 +13,14 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v6 - name: Generate the list of grants - run: uv run python _scripts/generate_grants.py > ./operations/grants.rst + run: uv run python scripts/generate_grants.py > ./docs/operations/grants.rst env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Create PR uses: peter-evans/create-pull-request@v7 with: token: ${{ secrets.GITHUB_TOKEN }} - add-paths: ./operations/grants.rst + add-paths: ./docs/operations/grants.rst commit-message: "update the list of grants (generated)" branch: automation/grants title: "Automated update of the list of grants" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f145758..a9c31c8 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,4 +12,4 @@ jobs: - name: Test run: uv run pytest - name: Build documentation - run: uv run sphinx-build -nWaE . _build + run: uv run sphinx-build -nWaE docs build diff --git a/.readthedocs.yml b/.readthedocs.yml index ae0b777..471219a 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -8,5 +8,5 @@ python: - method: pip path: . sphinx: - configuration: conf.py + configuration: docs/conf.py fail_on_warning: true diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 047785b..1a62b67 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -21,7 +21,7 @@ Když toho upravujete víc, nebo máte zálusk na nějaké složitější kejkle Běžná práce ----------- -#. Ve virtuálním prostředí spusťte projekt: ``uv sphinx-autobuild . _build`` +#. Ve virtuálním prostředí spusťte projekt: ``uv run sphinx-autobuild docs build`` #. Otevřete si v prohlížeči ``_ #. V editoru upravujete texty a v prohlížeči si kontrolujete výsledek #. Projekt zastavíte v terminálu pomocí :kbd:`Ctrl+C` @@ -95,7 +95,7 @@ Dokonce by to mělo automaticky zakládat i issue, pokud to najde nějaký probl Skript na generování zápisů hlasování o grantech ------------------------------------------------ -V adresáři ``_scripts`` je skript ``generate_grants.py``, který: +V adresáři ``scripts`` je skript ``generate_grants.py``, který: * se pomocí `GitHub Actions `_ jednou denně spustí, * vygeneruje soubor ``operations/grants.rst`` z dat na `pyvec/money `_ a ze šablony ``operations/grants.rst``, diff --git a/LICENSE b/LICENSE index a19a33f..4ee2644 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2024 Pyvec, z.s. +Copyright (c) 2025 Pyvec, z.s. Texty a obrázky materiálů jsou uvolněny pod licencí CC BY-SA 4.0 https://creativecommons.org/licenses/by-sa/4.0 diff --git a/LICENSE.MIT b/LICENSE.MIT index ad323e3..6a68a26 100644 --- a/LICENSE.MIT +++ b/LICENSE.MIT @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2024 Pyvec, z.s. +Copyright (c) 2025 Pyvec, z.s. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in diff --git a/_static/custom.css b/docs/_static/custom.css similarity index 100% rename from _static/custom.css rename to docs/_static/custom.css diff --git a/_static/images/community.svg b/docs/_static/images/community.svg similarity index 100% rename from _static/images/community.svg rename to docs/_static/images/community.svg diff --git a/_static/images/money.svg b/docs/_static/images/money.svg similarity index 100% rename from _static/images/money.svg rename to docs/_static/images/money.svg diff --git a/_static/images/org-i.svg b/docs/_static/images/org-i.svg similarity index 100% rename from _static/images/org-i.svg rename to docs/_static/images/org-i.svg diff --git a/_static/images/org.svg b/docs/_static/images/org.svg similarity index 100% rename from _static/images/org.svg rename to docs/_static/images/org.svg diff --git a/_static/images/pylady.svg b/docs/_static/images/pylady.svg similarity index 100% rename from _static/images/pylady.svg rename to docs/_static/images/pylady.svg diff --git a/_static/images/snake.svg b/docs/_static/images/snake.svg similarity index 100% rename from _static/images/snake.svg rename to docs/_static/images/snake.svg diff --git a/_static/images/ukulele.svg b/docs/_static/images/ukulele.svg similarity index 100% rename from _static/images/ukulele.svg rename to docs/_static/images/ukulele.svg diff --git a/_static/redirect.js b/docs/_static/redirect.js similarity index 100% rename from _static/redirect.js rename to docs/_static/redirect.js diff --git a/conf.py b/docs/conf.py similarity index 86% rename from conf.py rename to docs/conf.py index 5e160d0..927cc5a 100644 --- a/conf.py +++ b/docs/conf.py @@ -1,6 +1,15 @@ # Configuration file for the Sphinx documentation builder import os +import tomllib + + +# -- Metadata reading -------------------------------------------------------- + +with open("../pyproject.toml", "rb") as f: + pyproject = tomllib.load(f) +pyproject_version = pyproject["project"]["version"] +pyproject_name = pyproject["project"]["name"] # -- Project information ----------------------------------------------------- @@ -10,7 +19,7 @@ author = "Pyvec, z.s." # The short X.Y version -version = "" +version = pyproject_version # The full version, including alpha/beta/rc tags release = "" @@ -53,18 +62,7 @@ # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. # This pattern also affects html_static_path and html_extra_path . -exclude_patterns = [ - "_build", - "Thumbs.db", - ".DS_Store", - "venv", - ".venv", - ".github", - ".pytest_cache", - ".ruff_cache", - "src", - "tests", -] +exclude_patterns = ["Thumbs.db", ".DS_Store"] # The name of the Pygments (syntax highlighting) style to use. pygments_style = "monokai" @@ -89,7 +87,7 @@ # -- Options for HTMLHelp output --------------------------------------------- # Output file base name for HTML help builder. -htmlhelp_basename = "pyvec-doc" +htmlhelp_basename = pyproject_name # -- Options for LaTeX output ------------------------------------------------ @@ -100,7 +98,7 @@ # (source start file, target name, title, # author, documentclass [howto, manual, or own class]). latex_documents = [ - (master_doc, "pyvec.tex", project, author, "manual"), + (master_doc, pyproject_name + ".tex", project, author, "manual"), ] @@ -108,7 +106,7 @@ # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "pyvec", project, [author], 1)] +man_pages = [(master_doc, pyproject_name, project, [author], 1)] # -- Options for Texinfo output ---------------------------------------------- @@ -117,7 +115,7 @@ # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - (master_doc, "pyvec", project, author, "pyvec", project, "Miscellaneous"), + (master_doc, pyproject_name, project, author, pyproject_name, project, "Miscellaneous"), ] diff --git a/docs/contributing.rst b/docs/contributing.rst new file mode 100644 index 0000000..e582053 --- /dev/null +++ b/docs/contributing.rst @@ -0,0 +1 @@ +.. include:: ../CONTRIBUTING.rst diff --git a/guides/beginners-course.rst b/docs/guides/beginners-course.rst similarity index 100% rename from guides/beginners-course.rst rename to docs/guides/beginners-course.rst diff --git a/guides/calendar.rst b/docs/guides/calendar.rst similarity index 100% rename from guides/calendar.rst rename to docs/guides/calendar.rst diff --git a/guides/django-girls.rst b/docs/guides/django-girls.rst similarity index 100% rename from guides/django-girls.rst rename to docs/guides/django-girls.rst diff --git a/guides/high-school-class.rst b/docs/guides/high-school-class.rst similarity index 100% rename from guides/high-school-class.rst rename to docs/guides/high-school-class.rst diff --git a/guides/meetup.rst b/docs/guides/meetup.rst similarity index 100% rename from guides/meetup.rst rename to docs/guides/meetup.rst diff --git a/guides/promotion.rst b/docs/guides/promotion.rst similarity index 100% rename from guides/promotion.rst rename to docs/guides/promotion.rst diff --git a/guides/pyladies-runs.rst b/docs/guides/pyladies-runs.rst similarity index 100% rename from guides/pyladies-runs.rst rename to docs/guides/pyladies-runs.rst diff --git a/guides/pyworkings.rst b/docs/guides/pyworkings.rst similarity index 100% rename from guides/pyworkings.rst rename to docs/guides/pyworkings.rst diff --git a/guides/slido-moderation.rst b/docs/guides/slido-moderation.rst similarity index 100% rename from guides/slido-moderation.rst rename to docs/guides/slido-moderation.rst diff --git a/index.rst b/docs/index.rst similarity index 91% rename from index.rst rename to docs/index.rst index a598573..8a06424 100644 --- a/index.rst +++ b/docs/index.rst @@ -1,4 +1,4 @@ -.. include:: README.rst +.. include:: ../README.rst .. image:: _static/images/community.svg :width: 80% @@ -27,7 +27,7 @@ Obsah .. toctree:: :hidden: - CONTRIBUTING + contributing Navigace -------- diff --git a/operations/bylaws.rst b/docs/operations/bylaws.rst similarity index 100% rename from operations/bylaws.rst rename to docs/operations/bylaws.rst diff --git a/operations/domains.rst b/docs/operations/domains.rst similarity index 100% rename from operations/domains.rst rename to docs/operations/domains.rst diff --git a/operations/elections.rst b/docs/operations/elections.rst similarity index 100% rename from operations/elections.rst rename to docs/operations/elections.rst diff --git a/operations/glossary.rst b/docs/operations/glossary.rst similarity index 100% rename from operations/glossary.rst rename to docs/operations/glossary.rst diff --git a/operations/grants.rst b/docs/operations/grants.rst similarity index 98% rename from operations/grants.rst rename to docs/operations/grants.rst index f40d6fd..106048b 100644 --- a/operations/grants.rst +++ b/docs/operations/grants.rst @@ -3,7 +3,7 @@ Elektronická hlasování o grantech Od roku 2020 o grantech :term:`výbor ` hlasuje prostřednictvím repozitáře `pyvec/money `_. Zde je strojový přepis proběhlých hlasování. Kanonickým zdrojem pravdy je hlasování přímo na GitHub Issues. Kdyby něco nesedělo, ověřte `historii tohoto souboru `_ a funkčnost :ref:`přepisů `. -.. Soubor operations/grants.rst je generován skriptem _scripts/generate_grants.py ze šablony operations/grants.rst.jinja. Neupravovat ručně! +.. Soubor operations/grants.rst je generován skriptem scripts/generate_grants.py ze šablony operations/grants.rst.jinja. Neupravovat ručně! 18. 3. 2025 - elektronické hlasování výboru @@ -339,7 +339,7 @@ Dne 25. 7. 2023 požádal uživatel `@clytaemnestra `_ o Karolina Surma - PyLadies **Kolik potřebujete? (aspoň odhad nebo rozmezí)** - ~6800 Kč + ~6800 Kč *detailně* hlavička: 6.24 Kč / ks = 2496 Kč @@ -403,7 +403,7 @@ Dne 27. 2. 2023 požádal uživatel `@Zuzanita `_ o .. code-block:: text **Kdo jste?** - Organizátoři PyLadies - podává Zuzana Pokorná za všechny + Organizátoři PyLadies - podává Zuzana Pokorná za všechny **Kolik potřebujete? (aspoň odhad nebo rozmezí)** 25 000 Kč z toho bude část vrácena z příspěvků jednotlivců na trička @@ -613,7 +613,7 @@ Dne 16. 12. 2020 požádal uživatel `@kvbik `_ o gran **Kdo jste?** - Jakub Vysoky, clen Pyvec, spolu organizator prazskeho Pyva + Jakub Vysoky, clen Pyvec, spolu organizator prazskeho Pyva **Kolik potřebujete? (aspoň odhad nebo rozmezí)** @@ -621,7 +621,7 @@ Dne 16. 12. 2020 požádal uživatel `@kvbik `_ o gran **Na jakou věc to je?** - Letni edice Python komunitniho Sprintu ve Msenych-laznich v srpen 2020. + Letni edice Python komunitniho Sprintu ve Msenych-laznich v srpen 2020. **Proč? (čemu prospějeme, proč je to dobrý nápad, jaký to bude mít dopad?)** @@ -651,13 +651,13 @@ Dne 26. 2. 2020 požádal uživatel `@radusaaa `_ o PyLadies Praha **Kolik potřebujete? (aspoň odhad nebo rozmezí)** - 500,- Kč za oba běhy + 500,- Kč za oba běhy **Na jakou věc to je?** - kancelářské potřeby - - drobné odměny do soutěží + - drobné odměny do soutěží **Proč? (čemu prospějeme, proč je to dobrý nápad, jaký to bude mít dopad?)** Organizujeme dva běhy začátečnických kurzů viz https://pyladies.cz/praha/. Součástí kurzů jsou i dva sobotní celodenní pyworkingy a závěrečný hackathon. diff --git a/operations/grants.rst.jinja b/docs/operations/grants.rst.jinja similarity index 90% rename from operations/grants.rst.jinja rename to docs/operations/grants.rst.jinja index b6b2863..4a88c8c 100644 --- a/operations/grants.rst.jinja +++ b/docs/operations/grants.rst.jinja @@ -3,7 +3,7 @@ Elektronická hlasování o grantech Od roku 2020 o grantech :term:`výbor ` hlasuje prostřednictvím repozitáře `pyvec/money `_. Zde je strojový přepis proběhlých hlasování. Kanonickým zdrojem pravdy je hlasování přímo na GitHub Issues. Kdyby něco nesedělo, ověřte `historii tohoto souboru `_ a funkčnost :ref:`přepisů `. -.. Soubor operations/grants.rst je generován skriptem _scripts/generate_grants.py ze šablony operations/grants.rst.jinja. Neupravovat ručně! +.. Soubor operations/grants.rst je generován skriptem scripts/generate_grants.py ze šablony operations/grants.rst.jinja. Neupravovat ručně! {% for grant in grants %} {{ grant.voted_at.day }}. {{ grant.voted_at.month }}. {{ grant.voted_at.year }} - elektronické hlasování výboru diff --git a/operations/index.rst b/docs/operations/index.rst similarity index 100% rename from operations/index.rst rename to docs/operations/index.rst diff --git a/operations/meeting-notes.rst b/docs/operations/meeting-notes.rst similarity index 100% rename from operations/meeting-notes.rst rename to docs/operations/meeting-notes.rst diff --git a/operations/runbooks.rst b/docs/operations/runbooks.rst similarity index 100% rename from operations/runbooks.rst rename to docs/operations/runbooks.rst diff --git a/operations/support-money.rst b/docs/operations/support-money.rst similarity index 100% rename from operations/support-money.rst rename to docs/operations/support-money.rst diff --git a/operations/support.rst b/docs/operations/support.rst similarity index 100% rename from operations/support.rst rename to docs/operations/support.rst diff --git a/operations/twitter.rst b/docs/operations/twitter.rst similarity index 100% rename from operations/twitter.rst rename to docs/operations/twitter.rst diff --git a/operations/web-apps.rst b/docs/operations/web-apps.rst similarity index 100% rename from operations/web-apps.rst rename to docs/operations/web-apps.rst diff --git a/_scripts/generate_grants.py b/scripts/generate_grants.py similarity index 100% rename from _scripts/generate_grants.py rename to scripts/generate_grants.py diff --git a/uv.lock b/uv.lock index 3f21252..b14d874 100644 --- a/uv.lock +++ b/uv.lock @@ -304,7 +304,7 @@ requires-dist = [ { name = "jinja2", specifier = "==3.1.6" }, { name = "myst-parser", specifier = "==4.0.1" }, { name = "requests", specifier = "==2.32.3" }, - { name = "sphinx", specifier = "==8.1.3" }, + { name = "sphinx", specifier = "==8.2.3" }, { name = "sphinx-rtd-theme", specifier = "==3.0.2" }, { name = "sphinxemoji", specifier = "==0.3.1" }, { name = "strictyaml", specifier = "==1.7.3" }, @@ -349,6 +349,15 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/f9/9b/335f9764261e915ed497fcdeb11df5dfd6f7bf257d4a6a2a686d80da4d54/requests-2.32.3-py3-none-any.whl", hash = "sha256:70761cfe03c773ceb22aa2f671b4757976145175cdfca038c02654d061d6dcc6", size = 64928, upload-time = "2024-05-29T15:37:47.027Z" }, ] +[[package]] +name = "roman-numerals-py" +version = "3.1.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/30/76/48fd56d17c5bdbdf65609abbc67288728a98ed4c02919428d4f52d23b24b/roman_numerals_py-3.1.0.tar.gz", hash = "sha256:be4bf804f083a4ce001b5eb7e3c0862479d10f94c936f6c4e5f250aa5ff5bd2d", size = 9017, upload-time = "2025-02-22T07:34:54.333Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/53/97/d2cbbaa10c9b826af0e10fdf836e1bf344d9f0abb873ebc34d1f49642d3f/roman_numerals_py-3.1.0-py3-none-any.whl", hash = "sha256:9da2ad2fb670bcf24e81070ceb3be72f6c11c440d73bd579fbeca1e9f330954c", size = 7742, upload-time = "2025-02-22T07:34:52.422Z" }, +] + [[package]] name = "ruff" version = "0.11.8" @@ -403,7 +412,7 @@ wheels = [ [[package]] name = "sphinx" -version = "8.1.3" +version = "8.2.3" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "alabaster" }, @@ -415,6 +424,7 @@ dependencies = [ { name = "packaging" }, { name = "pygments" }, { name = "requests" }, + { name = "roman-numerals-py" }, { name = "snowballstemmer" }, { name = "sphinxcontrib-applehelp" }, { name = "sphinxcontrib-devhelp" }, @@ -423,9 +433,9 @@ dependencies = [ { name = "sphinxcontrib-qthelp" }, { name = "sphinxcontrib-serializinghtml" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/6f/6d/be0b61178fe2cdcb67e2a92fc9ebb488e3c51c4f74a36a7824c0adf23425/sphinx-8.1.3.tar.gz", hash = "sha256:43c1911eecb0d3e161ad78611bc905d1ad0e523e4ddc202a58a821773dc4c927", size = 8184611, upload-time = "2024-10-13T20:27:13.93Z" } +sdist = { url = "https://files.pythonhosted.org/packages/38/ad/4360e50ed56cb483667b8e6dadf2d3fda62359593faabbe749a27c4eaca6/sphinx-8.2.3.tar.gz", hash = "sha256:398ad29dee7f63a75888314e9424d40f52ce5a6a87ae88e7071e80af296ec348", size = 8321876, upload-time = "2025-03-02T22:31:59.658Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/26/60/1ddff83a56d33aaf6f10ec8ce84b4c007d9368b21008876fceda7e7381ef/sphinx-8.1.3-py3-none-any.whl", hash = "sha256:09719015511837b76bf6e03e42eb7595ac8c2e41eeb9c29c5b755c6b677992a2", size = 3487125, upload-time = "2024-10-13T20:27:10.448Z" }, + { url = "https://files.pythonhosted.org/packages/31/53/136e9eca6e0b9dc0e1962e2c908fbea2e5ac000c2a2fbd9a35797958c48b/sphinx-8.2.3-py3-none-any.whl", hash = "sha256:4405915165f13521d875a8c29c8970800a0141c14cc5416a38feca4ea5d9b9c3", size = 3589741, upload-time = "2025-03-02T22:31:56.836Z" }, ] [[package]]