ruff-sync 0.1.5.dev4__tar.gz → 0.1.5.dev6__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. ruff_sync-0.1.5.dev6/.agents/doc-fix.md +160 -0
  2. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mike/SKILL.md +75 -71
  3. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/ruff-sync-usage/references/ci-integration.md +11 -2
  4. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/SKILL.md +4 -0
  5. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/references/testing.md +9 -2
  6. ruff_sync-0.1.5.dev6/.agents/workflows/update-screenshots.md +52 -0
  7. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.github/workflows/ci.yaml +6 -9
  8. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/PKG-INFO +1 -1
  9. ruff_sync-0.1.5.dev6/docs/assets/github-job-summary.png +0 -0
  10. ruff_sync-0.1.5.dev6/docs/assets/inspect-main.png +0 -0
  11. ruff_sync-0.1.5.dev6/docs/assets/inspect-search.png +0 -0
  12. ruff_sync-0.1.5.dev6/docs/assets/screenshots/dashboard.svg +226 -0
  13. ruff_sync-0.1.5.dev6/docs/assets/screenshots/legend_help.svg +235 -0
  14. ruff_sync-0.1.5.dev6/docs/assets/screenshots/rule_details.svg +228 -0
  15. ruff_sync-0.1.5.dev6/docs/assets/screenshots/screenshot_sample.toml +53 -0
  16. ruff_sync-0.1.5.dev6/docs/assets/screenshots/search_omnibox.svg +221 -0
  17. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/ci-integration.md +10 -1
  18. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/gen_ref_pages.py +2 -1
  19. ruff_sync-0.1.5.dev6/docs/inspect.md +112 -0
  20. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/usage.md +5 -3
  21. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/mkdocs.yml +2 -1
  22. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/pyproject.toml +3 -1
  23. ruff_sync-0.1.5.dev6/scripts/generate_tui_screenshots.py +229 -0
  24. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/formatters.py +111 -20
  25. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/app.py +2 -0
  26. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/themes.py +1 -1
  27. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/widgets.py +28 -25
  28. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tasks.py +10 -0
  29. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_formatters.py +140 -31
  30. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/tui/test_tui.py +3 -2
  31. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/uv.lock +31 -1
  32. ruff_sync-0.1.5.dev4/.github/workflows/docs.yaml +0 -32
  33. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/DEPENDENCIES.md +0 -0
  34. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/TESTING.md +0 -0
  35. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/decisions/0001-type-refactoring-strategy.md +0 -0
  36. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/decisions/0002-tui-node-ast.md +0 -0
  37. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/decisions/README.md +0 -0
  38. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/formatters-architecture.md +0 -0
  39. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/gitlab-reports.md +0 -0
  40. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/issue-102-context.md +0 -0
  41. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/ruff.toml +0 -0
  42. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/adr/SKILL.md +0 -0
  43. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/dirty-equals/SKILL.md +0 -0
  44. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/dirty-equals/references/common-matchers.md +0 -0
  45. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/dirty-equals/references/toml-matching.md +0 -0
  46. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/dirty-equals/trigger_eval.json +0 -0
  47. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/gh-issues/SKILL.md +0 -0
  48. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mike/references/commands.md +0 -0
  49. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/SKILL.md +0 -0
  50. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/examples.md +0 -0
  51. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/templates/api-reference.md +0 -0
  52. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/templates/getting-started.md +0 -0
  53. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/templates/index.md +0 -0
  54. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/mkdocs-generation/templates/mkdocs.yml +0 -0
  55. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/release-notes-generation/SKILL.md +0 -0
  56. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/ruff-sync-usage/SKILL.md +0 -0
  57. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/ruff-sync-usage/references/configuration.md +0 -0
  58. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/ruff-sync-usage/references/troubleshooting.md +0 -0
  59. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/SKILL.md +0 -0
  60. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/best-practices.md +0 -0
  61. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/evaluating-skills.md +0 -0
  62. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/optimizing-descriptions.md +0 -0
  63. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/quickstart.md +0 -0
  64. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/sources.md +0 -0
  65. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/references/using-scripts.md +0 -0
  66. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/skill-creator/scripts/scaffold_skill.py +0 -0
  67. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/examples/basic_app.py +0 -0
  68. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/examples/reactive_example.py +0 -0
  69. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/references/events.md +0 -0
  70. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/references/styling.md +0 -0
  71. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/textual/references/widgets.md +0 -0
  72. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/SKILL.md +0 -0
  73. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/evals.json +0 -0
  74. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/advanced-narrowing.md +0 -0
  75. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/error-code-lookup.md +0 -0
  76. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/generics.md +0 -0
  77. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/naming.md +0 -0
  78. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/protocol-patterns.md +0 -0
  79. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/quickstart.md +0 -0
  80. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/references/refactoring-patterns.md +0 -0
  81. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/skills/type-checking/scripts/audit_types.py +0 -0
  82. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/tui_design.md +0 -0
  83. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/tui_requirements.md +0 -0
  84. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/tui_rule_browsing.md +0 -0
  85. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/tui_rule_browsing_design.md +0 -0
  86. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.agents/workflows/add-test-case.md +0 -0
  87. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.git-blame-ignore-revs +0 -0
  88. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.github/dependabot.yml +0 -0
  89. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.github/workflows/complexity.yaml +0 -0
  90. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.gitignore +0 -0
  91. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.pre-commit-config.yaml +0 -0
  92. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/.pre-commit-hooks.yaml +0 -0
  93. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/AGENTS.md +0 -0
  94. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/CONTRIBUTING.md +0 -0
  95. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/LICENSE.md +0 -0
  96. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/README.md +0 -0
  97. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/codecov.yml +0 -0
  98. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/configs/data-science-engineering/ruff.toml +0 -0
  99. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/configs/fastapi/ruff.toml +0 -0
  100. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/configs/kitchen-sink/ruff.toml +0 -0
  101. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/agent-skill.md +0 -0
  102. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/assets/favicon.png +0 -0
  103. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/assets/github-pr-annotation.png +0 -0
  104. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/assets/logo.png +0 -0
  105. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/assets/ruff_sync_banner.png +0 -0
  106. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/best-practices.md +0 -0
  107. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/configuration.md +0 -0
  108. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/contributing.md +0 -0
  109. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/examples/advanced-config.toml +0 -0
  110. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/examples/basic-config.toml +0 -0
  111. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/index.md +0 -0
  112. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/installation.md +0 -0
  113. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/overrides/main.html +0 -0
  114. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/overrides/partials/version_warning.html +0 -0
  115. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/pre-commit.md +0 -0
  116. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/pre-defined-configs.md +0 -0
  117. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/troubleshooting.md +0 -0
  118. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/docs/url-resolution.md +0 -0
  119. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/scripts/check_dogfood.sh +0 -0
  120. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/scripts/gitclone_dogfood.sh +0 -0
  121. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/scripts/pull_dogfood.sh +0 -0
  122. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/skills-lock.json +0 -0
  123. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/__init__.py +0 -0
  124. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/__main__.py +0 -0
  125. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/cli.py +0 -0
  126. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/config_io.py +0 -0
  127. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/constants.py +0 -0
  128. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/core.py +0 -0
  129. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/dependencies.py +0 -0
  130. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/pre_commit.py +0 -0
  131. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/system.py +0 -0
  132. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/__init__.py +0 -0
  133. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/constants.py +0 -0
  134. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/screens.py +0 -0
  135. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/tui/types_.py +0 -0
  136. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/src/ruff_sync/types_.py +0 -0
  137. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/__init__.py +0 -0
  138. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/conftest.py +0 -0
  139. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/multi_upstream_final.toml +0 -0
  140. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/multi_upstream_initial.toml +0 -0
  141. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/multi_upstream_up1.toml +0 -0
  142. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/multi_upstream_up2.toml +0 -0
  143. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_changes_final.toml +0 -0
  144. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_changes_initial.toml +0 -0
  145. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_changes_upstream.toml +0 -0
  146. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_dotted_keys_final.toml +0 -0
  147. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_dotted_keys_initial.toml +0 -0
  148. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_dotted_keys_upstream.toml +0 -0
  149. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_ruff_cfg_final.toml +0 -0
  150. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_ruff_cfg_initial.toml +0 -0
  151. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/no_ruff_cfg_upstream.toml +0 -0
  152. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/readme_excludes_final.toml +0 -0
  153. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/readme_excludes_initial.toml +0 -0
  154. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/readme_excludes_upstream.toml +0 -0
  155. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/standard_final.toml +0 -0
  156. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/standard_initial.toml +0 -0
  157. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/lifecycle_tomls/standard_upstream.toml +0 -0
  158. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/ruff.toml +0 -0
  159. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_basic.py +0 -0
  160. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_check.py +0 -0
  161. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_ci_integration.py +0 -0
  162. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_ci_validation.py +0 -0
  163. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_config_io.py +0 -0
  164. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_config_validation.py +0 -0
  165. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_constants.py +0 -0
  166. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_corner_cases.py +0 -0
  167. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_dependencies.py +0 -0
  168. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_deprecation.py +0 -0
  169. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_e2e.py +0 -0
  170. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_git_fetch.py +0 -0
  171. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_minimal_imports.sh +0 -0
  172. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_pre_commit.py +0 -0
  173. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_project.py +0 -0
  174. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_rule_logic.py +0 -0
  175. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_scaffold.py +0 -0
  176. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_serialization.py +0 -0
  177. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_system.py +0 -0
  178. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_toml_operations.py +0 -0
  179. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_url_handling.py +0 -0
  180. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/test_whitespace.py +0 -0
  181. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/tui/__init__.py +0 -0
  182. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/tui/conftest.py +0 -0
  183. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/tui/test_themes.py +0 -0
  184. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/tui/test_tui_types.py +0 -0
  185. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/w_ruff_sync_cfg/pyproject.toml +0 -0
  186. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/wo_ruff_cfg/pyproject.toml +0 -0
  187. {ruff_sync-0.1.5.dev4 → ruff_sync-0.1.5.dev6}/tests/wo_ruff_sync_cfg/pyproject.toml +0 -0
@@ -0,0 +1,160 @@
1
+ # Fix Versioned Documentation CI (`mike` + MkDocs)
2
+
3
+ ## Summary
4
+
5
+ After researching the official `mike` README, Material for MkDocs docs, and comparing against real-world projects, the current setup has **one fatal flaw** and several secondary problems that have caused versioning to never work correctly.
6
+
7
+ ---
8
+
9
+ ## Root Cause: Two Workflows Fighting Each Other
10
+
11
+ The most critical issue is that **two separate workflows both deploy docs to `gh-pages` on every push to `main`**, and they use incompatible methods:
12
+
13
+ | Workflow | Trigger | Command | Effect |
14
+ |---|---|---|---|
15
+ | `ci.yaml` → `publish-docs` | push to `main` | `mike deploy --push dev` | Appends a `dev/` directory and `versions.json` to `gh-pages` |
16
+ | `docs.yaml` → `deploy` | push to `main` | `mkdocs gh-deploy --force` | **Completely overwrites the entire `gh-pages` branch** |
17
+
18
+ `mkdocs gh-deploy --force` does not know about `mike`. It builds a flat site and force-pushes it as the **sole content** of `gh-pages`. This destroys everything `mike` deployed, including `versions.json`, the `dev/` subdirectory, and the root redirect.
19
+
20
+ **This is why versioning has never worked: `docs.yaml` immediately destroys `mike`'s work.**
21
+
22
+ ---
23
+
24
+ ## Secondary Issues
25
+
26
+ ### 1. Wrong `alias_type` in `mkdocs.yml`
27
+ - `alias_type: copy` is set, but for GitHub Pages `redirect` is the most reliable option. `copy` creates full file copies for every alias, meaning the `stable` alias contains a complete separate copy of docs that becomes stale when the `stable` alias moves. `symlink` is the default and works on most servers, but GitHub Pages does not follow actual symlinks. `redirect` creates a thin HTML redirect per page at the alias path — the correct approach for GitHub Pages.
28
+
29
+ ### 2. Invalid `mike alias --push stable stable` bootstrap
30
+ - The CI attempts `mike alias --push stable stable` to "ensure `stable` exists." This is nonsensical — it tries to create an alias called `stable` pointing to `stable` (which doesn't exist yet). Mike will error, and the `|| true` suppresses it. It achieves nothing.
31
+
32
+ ### 3. `mike deploy --update-aliases dev` on stable releases
33
+ - When releasing `0.1.4 stable`, the CI also runs `mike deploy --push --update-aliases dev`. This re-deploys the current commit as *both* the stable `0.1.4` and the `dev` version, which makes `dev` identical to `stable`. `dev` should only be updated on commits to `main` when the version is a dev pre-release.
34
+
35
+ ### 4. The `validate-docs-build` job is fine but could use `--no-directory-urls`
36
+ - `mkdocs build --strict` is a good validation step on PRs. No change needed.
37
+
38
+ ---
39
+
40
+ ## Proposed Changes
41
+
42
+ ### [`DELETE`] `.github/workflows/docs.yaml`
43
+
44
+ This file is the root cause. It must be deleted. All documentation deployment must happen exclusively through `mike` in `ci.yaml`.
45
+
46
+ ---
47
+
48
+ ### [`MODIFY`] `.github/workflows/ci.yaml` — `publish-docs` job
49
+
50
+ **Fix the deploy logic:**
51
+
52
+ ```yaml
53
+ publish-docs:
54
+ name: Publish Documentation
55
+ if: github.event_name == 'push' && github.ref == 'refs/heads/main'
56
+ needs: [pre-publish]
57
+ runs-on: ubuntu-latest
58
+ permissions:
59
+ contents: write
60
+ steps:
61
+ - name: Checkout
62
+ uses: actions/checkout@v4
63
+ with:
64
+ fetch-depth: 0
65
+
66
+ - name: Fetch gh-pages branch
67
+ # mike needs the gh-pages branch history to make incremental commits.
68
+ # Without this, mike may fail or corrupt the branch.
69
+ run: git fetch origin gh-pages --depth=1 || true
70
+
71
+ - name: Install uv
72
+ uses: astral-sh/setup-uv@v5
73
+
74
+ - name: Set up Python
75
+ run: uv python install 3.10
76
+
77
+ - name: Install dependencies
78
+ run: uv sync --group docs --frozen
79
+
80
+ - name: Configure git
81
+ run: |
82
+ git config user.name "github-actions[bot]"
83
+ git config user.email "github-actions[bot]@users.noreply.github.com"
84
+
85
+ - name: Extract version
86
+ id: version
87
+ run: |
88
+ VERSION=$(uv run python -c "
89
+ import pathlib, tomlkit
90
+ data = tomlkit.parse(pathlib.Path('pyproject.toml').read_text(encoding='utf-8'))
91
+ version = data.get('project', {}).get('version') or data.get('version')
92
+ if not version: raise SystemExit('Version not found')
93
+ print(version)
94
+ ")
95
+ echo "version=$VERSION" >> $GITHUB_OUTPUT
96
+ echo "Current Version: $VERSION"
97
+
98
+ - name: Deploy dev documentation
99
+ if: contains(steps.version.outputs.version, '.dev')
100
+ run: uv run mike deploy --push --update-aliases dev
101
+
102
+ - name: Deploy stable documentation
103
+ if: "!contains(steps.version.outputs.version, '.dev')"
104
+ run: |
105
+ VERSION="${{ steps.version.outputs.version }}"
106
+ uv run mike deploy --push --update-aliases "$VERSION" stable
107
+ uv run mike set-default --push stable
108
+ ```
109
+
110
+ **Key changes from current:**
111
+ 1. Added `git fetch origin gh-pages --depth=1 || true` — required by mike to make incremental commits (per the mike README CI section).
112
+ 2. Split the version extraction into its own step with `id: version` so it can be used in `if` conditions.
113
+ 3. `dev` is **only** deployed when the version string contains `.dev`. The stable deploy no longer also writes a `dev` alias.
114
+ 4. Removed the bogus `mike alias --push stable stable || true` bootstrap.
115
+
116
+ ---
117
+
118
+ ### [`MODIFY`] `mkdocs.yml` — Fix `alias_type`
119
+
120
+ Change `alias_type` from `copy` to `redirect`:
121
+
122
+ ```yaml
123
+ plugins:
124
+ - mike:
125
+ alias_type: redirect # was: copy
126
+ canonical_version: stable
127
+ ```
128
+
129
+ `redirect` is the correct choice for GitHub Pages: it creates a lightweight `.html` redirect file at the alias path for every page (e.g., `stable/index.html` redirects to `0.1.4/index.html`). Unlike `symlink`, it works reliably on GitHub Pages. Unlike `copy`, it doesn't create diverging stale copies.
130
+
131
+ ---
132
+
133
+ ### [`MODIFY`] `.agents/skills/mike/SKILL.md`
134
+
135
+ - Remove the failed repair history section (no longer relevant once fixed)
136
+ - Update the CI workflow documentation to reflect the corrected single-workflow approach
137
+ - Document the critical `git fetch origin gh-pages --depth=1` requirement
138
+ - Document why `docs.yaml` must not exist alongside `mike deploy`
139
+ - Update `alias_type` guidance from `copy` to `redirect`
140
+
141
+ ---
142
+
143
+ ## Verification Plan
144
+
145
+ ### After merging:
146
+ 1. Check that `docs.yaml` is deleted and only `ci.yaml` deploys docs.
147
+ 2. Watch the next CI run on `main` — the `publish-docs` job should run `mike deploy --push --update-aliases dev`.
148
+ 3. Check the `gh-pages` branch: it should contain a `dev/` directory, a `versions.json`, and a root `index.html` redirect.
149
+ 4. Visit `https://kilo59.github.io/ruff-sync/` — it should redirect to `dev/` (since no stable version has been deployed yet).
150
+ 5. The version selector in the Material theme should appear showing `dev`.
151
+
152
+ ### For stable releases:
153
+ When version is bumped to a non-dev release and merged:
154
+ - `0.x.y/` directory appears on `gh-pages`
155
+ - `stable` alias points to `0.x.y/` via redirects
156
+ - Root redirects to `stable/`
157
+ - Version selector shows both `0.x.y [stable]` and `dev`
158
+
159
+ > [!IMPORTANT]
160
+ > After deploying, you may need to manually run a one-time `mike deploy --push dev` locally (or trigger the CI) to bootstrap the `gh-pages` branch if it currently contains a flat `mkdocs gh-deploy` dump. You may first want to run `mike delete --all --push` to wipe the broken state.
@@ -18,10 +18,27 @@ uv sync --group docs
18
18
  ## Project Strategy
19
19
 
20
20
  This project follows a specific versioning strategy:
21
- 1. **`dev`**: Represents the current `main` branch.
22
- 2. **Stable Releases**: Versioned documentation (e.g., `0.1.4`) created upon release.
21
+ 1. **`dev`**: Represents the current `main` branch. Deployed on every push to `main` when the version string contains `.dev`.
22
+ 2. **Stable Releases**: Versioned documentation (e.g., `0.1.4`) created upon release — when the version string does NOT contain `.dev`.
23
23
  3. **`stable`**: An alias always pointing to the most recent non-dev release.
24
- 4. **`latest`**: An alias pointing to the most recent release (including dev, if applicable).
24
+
25
+ ## mkdocs.yml Configuration
26
+
27
+ ```yaml
28
+ extra:
29
+ version:
30
+ provider: mike
31
+
32
+ plugins:
33
+ - mike:
34
+ alias_type: redirect # NOT 'copy' or 'symlink' — redirect is correct for GitHub Pages
35
+ canonical_version: stable
36
+ ```
37
+
38
+ ### Why `alias_type: redirect`?
39
+ - **`symlink`** (default): Creates actual filesystem symlinks. GitHub Pages does not follow symlinks — the alias directory appears empty.
40
+ - **`copy`**: Duplicates all files at the alias path. Creates stale copies when the alias moves to a new version.
41
+ - **`redirect`**: Creates a thin HTML redirect file for each page at the alias path. Works correctly on GitHub Pages and stays current because it redirects to the canonical versioned path.
25
42
 
26
43
  ## Theme Overrides
27
44
 
@@ -35,13 +52,7 @@ theme:
35
52
 
36
53
  ### Version switcher
37
54
 
38
- The version switcher is enabled via `extra.version.provider: mike`:
39
-
40
- ```yaml
41
- extra:
42
- version:
43
- provider: mike
44
- ```
55
+ The version switcher is enabled via `extra.version.provider: mike` (shown above).
45
56
 
46
57
  ## Versioning Banner
47
58
 
@@ -51,48 +62,40 @@ A custom banner is displayed when users are viewing the `dev` documentation. Thi
51
62
  - `main.html`: Extends the base template and includes the `version_warning.html` partial at the start of the `content` block.
52
63
  - `version_warning.html`: Contains an HTML snippet that is hidden by default and shown via JavaScript if the URL path contains `/dev/`.
53
64
 
54
- Example in `version_warning.html`:
55
- ```html
56
- <div id="version-warning" style="display: none;">
57
- <div class="admonition warning">
58
- <p class="admonition-title">Warning</p>
59
- <p>
60
- You are viewing the documentation for the <strong>development</strong> version.
61
- The latest stable release can be found at <a href="https://kilo59.github.io/ruff-sync/">kilo59.github.io/ruff-sync</a>.
62
- </p>
63
- </div>
64
- </div>
65
- <script>
66
- (function() {
67
- const version_warning = document.getElementById("version-warning");
68
- if (!version_warning) return;
69
-
70
- // mike provides a 'mike' object with some metadata if available
71
- // Otherwise fall back to checking the pathname
72
- const isDev = window.location.pathname.includes("/dev/") ||
73
- (window.mike && typeof window.mike.version === 'string' && window.mike.version === "dev");
74
-
75
- if (isDev) {
76
- version_warning.style.display = "block";
77
- }
78
- })();
79
- </script>
80
- ```
65
+ ## CI/CD Integration
81
66
 
82
- ### 1. Deploying Development Docs
83
- Run this from the `main` branch to update the `dev` version:
84
- ```bash
85
- mike deploy dev --push --update-aliases
86
- ```
67
+ > [!CAUTION]
68
+ > **Golden Rule**: Only ONE workflow may ever write to `gh-pages`. If two workflows both deploy to `gh-pages`, the second one will overwrite the first, destroying `versions.json` and all versioned directories.
69
+ >
70
+ > **Never** use `mkdocs gh-deploy` alongside `mike deploy` they are mutually exclusive deployment strategies. This project uses `mike deploy` exclusively. There is no `docs.yaml` workflow; all deployment happens in `ci.yaml`.
87
71
 
88
- ### 2. Deploying a Stable Release
89
- When a new version is released (e.g., `0.1.4`), deploy it and update the `stable` alias:
90
- ```bash
91
- # Deploy the specific version and update 'stable'
92
- mike deploy 0.1.4 stable --push --update-aliases
72
+ The deployment logic is automated in [.github/workflows/ci.yaml](.github/workflows/ci.yaml). The `publish-docs` job:
93
73
 
94
- # Set 'stable' as the default version for the site root
95
- mike set-default --push stable
74
+ 1. **Fetches the `gh-pages` branch** before deploying this is required by mike to make incremental commits. Without it, mike may reset the entire branch.
75
+ 2. **Detects the version** from `pyproject.toml` using `tomlkit`.
76
+ 3. **Deploys `dev`** if the version string contains `.dev`.
77
+ 4. **Deploys a versioned release + `stable` alias** and sets `stable` as the default if not a dev version.
78
+
79
+ ### Key CI snippet
80
+
81
+ ```yaml
82
+ - name: Fetch gh-pages branch
83
+ # Required: mike needs the gh-pages branch history for incremental commits.
84
+ run: git fetch origin gh-pages --depth=1 || true
85
+
86
+ - name: Deploy documentation
87
+ run: |
88
+ git config user.name "github-actions[bot]"
89
+ git config user.email "github-actions[bot]@users.noreply.github.com"
90
+
91
+ VERSION=$(uv run python -c "...")
92
+
93
+ if [[ "$VERSION" == *".dev"* ]]; then
94
+ uv run mike deploy --push --update-aliases dev
95
+ else
96
+ uv run mike deploy --push --update-aliases "$VERSION" stable
97
+ uv run mike set-default --push stable
98
+ fi
96
99
  ```
97
100
 
98
101
  ## Reference Commands
@@ -104,13 +107,23 @@ mike set-default --push stable
104
107
  | **Set Default** | `mike set-default <version>` |
105
108
  | **Alias** | `mike alias <version> <alias>` |
106
109
  | **Delete** | `mike delete <identifier>` |
110
+ | **Delete all** | `mike delete --all` |
107
111
 
108
- ## CI/CD Integration
112
+ ### Deploying Development Docs
113
+ Run this from the `main` branch to update the `dev` version:
114
+ ```bash
115
+ mike deploy dev --push --update-aliases
116
+ ```
109
117
 
110
- The deployment logic is automated in [.github/workflows/ci.yaml](.github/workflows/ci.yaml). It automatically:
111
- - Extracts the version from `pyproject.toml`.
112
- - Deploys to `dev` if the version contains `.dev`.
113
- - Deploys to `<version>` and updates `stable` for official releases.
118
+ ### Deploying a Stable Release
119
+ When a new version is released (e.g., `0.1.4`), deploy it and update the `stable` alias:
120
+ ```bash
121
+ # Deploy the specific version and update 'stable'
122
+ mike deploy 0.1.4 stable --push --update-aliases
123
+
124
+ # Set 'stable' as the default version for the site root
125
+ mike set-default --push stable
126
+ ```
114
127
 
115
128
  > [!IMPORTANT]
116
129
  > **Do NOT** use `mike install-gh-pages`. It is deprecated and removed in the version used by this project. `mike deploy` handles branch initialization automatically.
@@ -130,21 +143,12 @@ The deployment logic is automated in [.github/workflows/ci.yaml](.github/workflo
130
143
  ### 404 for `versions.json`
131
144
  - If you see a 404 for `/versions.json` but `https://<user>.github.io/<repo>/versions.json` exists, the switcher is looking at the domain root instead of the project root. Verify `site_url` includes the repository name and has a trailing slash.
132
145
 
133
- ## Post-Mortem & Known Issues
146
+ ### Corrupted/Stale `gh-pages` Branch
147
+ If the `gh-pages` branch was written by `mkdocs gh-deploy` instead of mike, it will be a flat site with no versioning. To reset:
134
148
 
135
- > [!CAUTION]
136
- > **Current Status**: Documentation versioning is currently **BROKEN** on the live site (`kilo59.github.io/ruff-sync`).
137
-
138
- ### Failed Repair History
139
- The following fixes have been attempted and **FAILED** to resolve the issue:
140
- 1. **Lowercasing `site_url`**: Normalizing the repository name in the URL (e.g., `ruff-sync` instead of `Ruff-Sync`) did not fix the 404s for `versions.json`.
141
- 2. **Removing `theme.version`**: Removing the redundant Material 9.x config did not restore the switcher.
142
- 3. **Adding `canonical_version: stable`**: Adding this to the `mike` plugin in `mkdocs.yml` was intended to fix path resolution but has not fixed the root page 404.
143
- 4. **CI Restoration Logic**: Adding `mike alias --push stable stable` to the CI to manually repair `versions.json` hasn't restored the picker on the root page.
144
-
145
- ### Root Cause Suspicions
146
- - **GitHub Pages Subfolder Pathing**: The site is served from a subfolder (`/ruff-sync/`). `mike`'s JavaScript for the version switcher frequently struggles with calculating relative paths to `versions.json` when served from a subfolder if `site_url` or base paths are not perfectly aligned with the deployment environment.
147
- - **`versions.json` Drift**: The `versions.json` file on the `gh-pages` branch frequently becomes desynchronized or loses the `stable` entry, which triggers `mkdocs-material` to hide the switcher entirely.
148
-
149
- ### Guidance for Future Agents
150
- Before attempting another "fix," you **MUST** verify the current state of `versions.json` on the `gh-pages` branch and check the browser console on the live site for 404 paths. Do not assume standard configurations will work without manual verification of the deployed assets.
149
+ ```bash
150
+ # WARNING: This deletes all deployed docs. Run locally, then push.
151
+ uv run mike delete --all --push
152
+ # Then trigger a CI run or deploy manually:
153
+ uv run mike deploy --push --update-aliases dev
154
+ ```
@@ -12,7 +12,10 @@ Add this step to any existing workflow (e.g., `.github/workflows/ci.yaml`):
12
12
  ```
13
13
 
14
14
  `--semantic` ignores cosmetic differences (comments, whitespace) — only real value or rule changes cause failure.
15
- `--output-format github` creates inline PR annotations for errors and warnings.
15
+ `--output-format github` creates inline PR annotations and a structured Job Summary report.
16
+
17
+ > [!TIP]
18
+ > `ruff-sync` automatically groups multiple drifts in the same file into a single annotation to reduce PR noise.
16
19
 
17
20
  ### Full Workflow Example
18
21
 
@@ -73,7 +76,13 @@ For repositories with GitHub Advanced Security enabled, upload SARIF results to
73
76
  The `|| true` ensures the upload step always runs even when `ruff-sync` exits 1 (drift detected). Without it, GitHub Actions would skip the upload step on failure.
74
77
 
75
78
  > **Why SARIF over `--output-format github`?**
76
- > The `github` format creates ephemeral workflow annotations that disappear once the check re-runs. SARIF findings are persisted in the Security tab, tracked as "introduced" and "resolved" across branches, and each drifted TOML key (`lint.select`, `target-version`, etc.) is a separate finding with a stable fingerprint — making it easy to trend configuration health over time.
79
+ >
80
+ > | Feature | `github` | `sarif` |
81
+ > |---------|----------|---------|
82
+ > | **PR Feedback** | Inline annotations (grouped) | Inline annotations (per-key) |
83
+ > | **Job Summary** | ✅ Markdown table | ❌ (requires separate parsing) |
84
+ > | **Persistence** | Ephemeral (until re-run) | Persistent (Security tab) |
85
+ > | **Tracking** | Manual | Automated "introduced/resolved" |
77
86
 
78
87
  ---
79
88
 
@@ -51,3 +51,7 @@ if __name__ == "__main__":
51
51
  > - **Async Handlers**: Event handlers can be `async def` or `def`. Use `async` if you need to `await` I/O or `post_message`.
52
52
  > - **Main Thread**: Do not block the main thread with long-running synchronous code. Use `self.run_worker()` for background tasks.
53
53
  - **Theme Tokens in Rich Markup**: Textual theme tokens (e.g., `$success`, `$accent`) **cannot** be used directly in Rich markup strings (like in `DataTable` cells). They must be resolved to hex strings at runtime: `str(self.app.get_theme(self.app.theme).success)`.
54
+ - **Type-Safe Queries (No Cast)**: If `typing.cast` is banned (e.g. by `TID251`), use a variable annotation with a targeted `# type: ignore` to resolve `query_one` results:
55
+ ```python
56
+ tree: MyTree = app.query_one("#tree-id") # type: ignore[assignment]
57
+ ```
@@ -51,8 +51,15 @@ async with app.run_test() as pilot:
51
51
  assert app.query_one(Input).value == "hello"
52
52
  ```
53
53
 
54
- ### Waiting for Animations/I/O
55
- If your UI has transitions or performs background work, use `pilot.wait_for_scheduled_animations()` or simply `await pilot.pause(0.1)`.
54
+ ### Brittle Navigation & Expansion
55
+ When navigating complex structures like a `Tree` with many nodes:
56
+ - **Expansion Wait**: Expanding a node (`pilot.press("right")`) is asynchronous. If the number of child nodes is large, you MUST provide a significant `pilot.pause()` (e.g., 1.5s - 2.0s) before attempting to select or search for children.
57
+ - **Search-and-Verify**: Instead of fixed `down` counts, use a verification loop with a small `pilot.pause(0.02)` between steps to wait for cursor updates.
58
+
59
+ ### 📸 Automated Screenshots (SVG)
60
+ When using `app.save_screenshot()` in a test:
61
+ - **Visibility Matters**: Only widgets and rows that are currently "scrolled into view" are captured in the SVG. Large tables or trees will be truncated unless you explicitly scroll.
62
+ - **Size Specification**: Define a repeatable terminal size in `run_test(size=(W, H))` to ensure consistent screenshot layouts across environments.
56
63
 
57
64
  > [!IMPORTANT]
58
65
  > Always use `pytest-asyncio` with the `@pytest.mark.asyncio` decorator for Textual tests. The boilerplate provided in `app.run_test()` handles the event loop lifecycle for you.
@@ -0,0 +1,52 @@
1
+ ---
2
+ description: Regenerate TUI screenshots for documentation
3
+ ---
4
+
5
+ Use this workflow to update the SVG screenshots of the Ruff-Sync TUI when the user interface, theme, or major features change.
6
+
7
+ ### 1. Regenerate Screenshots
8
+ // turbo
9
+ 1. Run the automated screenshot generation task:
10
+ ```bash
11
+ uv run invoke screenshots
12
+ ```
13
+ *This script launches the TUI headlessly using Textual's testing harness and captures key views to `docs/assets/screenshots/`.*
14
+
15
+ ### 2. Verify Output
16
+ 1. Check the `docs/assets/screenshots/` directory for updated `.svg` files:
17
+ - `dashboard.svg`
18
+ - `rule_details.svg`
19
+ - `search_omnibox.svg`
20
+ - `legend_help.svg`
21
+ 2. Ensure the screenshots correctly reflect the current state of the application.
22
+
23
+ ### 3. Update Documentation (Optional)
24
+ 1. If new views were added or filenames changed, update the relevant markdown files in `docs/` or `mkdocs.yml`.
25
+
26
+ ### 4. Commit Changes
27
+ 1. Stage and commit the updated assets:
28
+ ```bash
29
+ git add docs/assets/screenshots/*.svg
30
+ git commit -m "docs: update TUI screenshots"
31
+ ```
32
+
33
+ ---
34
+
35
+ ### Adding a New Screenshot View
36
+
37
+ To add a new view to the automated screenshot rotation:
38
+
39
+ 1. **Modify the Script**: Edit `scripts/generate_tui_screenshots.py`.
40
+ 2. **Add Navigation**: Use `pilot` commands within the `async with app.run_test()` block:
41
+ ```python
42
+ # Navigate to the new view
43
+ await pilot.press("control+f") # Example: Open a specific dialog
44
+ await pilot.pause(0.2) # Give the UI time to animate
45
+ ```
46
+ 3. **Capture the Screen**:
47
+ ```python
48
+ path = SCREENSHOTS_DIR / "my_new_view.svg"
49
+ app.save_screenshot(str(path))
50
+ ```
51
+ 4. **Update Documentation**: Add the new SVG to the relevant Markdown file or `mkdocs.yml`.
52
+ 5. **Regenerate**: Run `uv run invoke screenshots` to verify the new capture works as expected.
@@ -175,14 +175,17 @@ jobs:
175
175
  - name: Install dependencies
176
176
  run: uv sync --group docs --frozen
177
177
 
178
+ - name: Fetch gh-pages branch
179
+ # mike needs the gh-pages branch history to make incremental commits.
180
+ # Without fetching it first, mike may reset the entire branch.
181
+ run: git fetch origin gh-pages --depth=1 || true
182
+
178
183
  - name: Deploy documentation
179
184
  run: |
180
185
  # Configure git
181
186
  git config user.name "github-actions[bot]"
182
187
  git config user.email "github-actions[bot]@users.noreply.github.com"
183
188
 
184
- # mike deploy handles gh-pages initialization automatically
185
-
186
189
  # Extract version from pyproject.toml in a TOML-aware way using already installed dependencies
187
190
  VERSION=$(uv run python - << 'PY'
188
191
  import pathlib
@@ -205,17 +208,11 @@ jobs:
205
208
 
206
209
  if [[ "$VERSION" == *".dev"* ]]; then
207
210
  echo "Deploying DEV documentation..."
208
- # Ensure 'stable' exists in versions.json so the switcher doesn't disappear.
209
- # 'mike alias' will create it if missing, pointing to the current stable root.
210
- # We use --push to ensure versions.json is updated on gh-pages.
211
- uv run mike alias --push stable stable || true
212
211
  uv run mike deploy --push --update-aliases dev
213
212
  else
214
213
  echo "Deploying STABLE documentation..."
215
- uv run mike deploy --push --update-aliases $VERSION stable
214
+ uv run mike deploy --push --update-aliases "$VERSION" stable
216
215
  uv run mike set-default --push stable
217
- # Also update dev to match stable on a full release
218
- uv run mike deploy --push --update-aliases dev
219
216
  fi
220
217
 
221
218
  publish:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ruff-sync
3
- Version: 0.1.5.dev4
3
+ Version: 0.1.5.dev6
4
4
  Summary: Synchronize Ruff linter configuration across projects
5
5
  Project-URL: Homepage, https://github.com/Kilo59/ruff-sync
6
6
  Project-URL: Documentation, https://kilo59.github.io/ruff-sync/