git-nested 1.2.0__tar.gz → 1.2.1__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 (181) hide show
  1. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/docs.yml +11 -5
  2. {git_nested-1.2.0/src/git_nested.egg-info → git_nested-1.2.1}/PKG-INFO +3 -1
  3. {git_nested-1.2.0 → git_nested-1.2.1}/README.md +2 -0
  4. {git_nested-1.2.0 → git_nested-1.2.1}/doc/README.md +2 -0
  5. {git_nested-1.2.0 → git_nested-1.2.1}/doc/_static/custom.css +9 -0
  6. git_nested-1.2.1/doc/_static/favicon.svg +29 -0
  7. git_nested-1.2.1/doc/_static/logo.svg +30 -0
  8. {git_nested-1.2.0 → git_nested-1.2.1}/doc/architecture/diagrams.md +7 -7
  9. {git_nested-1.2.0 → git_nested-1.2.1}/doc/architecture/index.md +1 -1
  10. {git_nested-1.2.0 → git_nested-1.2.1}/doc/concepts/glossary.md +1 -1
  11. {git_nested-1.2.0 → git_nested-1.2.1}/doc/conf.py +4 -0
  12. git_nested-1.2.1/doc/configuration/examples.md +259 -0
  13. {git_nested-1.2.0 → git_nested-1.2.1}/doc/configuration/git-config.md +11 -0
  14. {git_nested-1.2.0 → git_nested-1.2.1}/doc/configuration/gitnested-file.md +28 -1
  15. {git_nested-1.2.0 → git_nested-1.2.1}/doc/contributing/documentation.md +3 -0
  16. {git_nested-1.2.0 → git_nested-1.2.1}/doc/index.md +4 -0
  17. {git_nested-1.2.0 → git_nested-1.2.1}/doc/introduction/index.md +2 -0
  18. {git_nested-1.2.0 → git_nested-1.2.1}/doc/introduction/install.md +17 -0
  19. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/setup.py +3 -0
  20. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/config.py +4 -4
  21. git_nested-1.2.1/src/git_nested/configio.py +91 -0
  22. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/gitfile.py +17 -6
  23. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/history.py +3 -5
  24. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/models.py +3 -4
  25. {git_nested-1.2.0 → git_nested-1.2.1/src/git_nested.egg-info}/PKG-INFO +3 -1
  26. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/SOURCES.txt +6 -1
  27. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/scm_file_list.json +6 -1
  28. git_nested-1.2.1/src/git_nested.egg-info/scm_version.json +8 -0
  29. git_nested-1.2.1/tests/e2e/test_toml.py +55 -0
  30. git_nested-1.2.1/tests/unit/test_configio.py +108 -0
  31. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_helpers.py +2 -2
  32. git_nested-1.2.0/src/git_nested/yamlio.py +0 -25
  33. git_nested-1.2.0/src/git_nested.egg-info/scm_version.json +0 -8
  34. {git_nested-1.2.0 → git_nested-1.2.1}/.codecov.yml +0 -0
  35. {git_nested-1.2.0 → git_nested-1.2.1}/.fish.rc +0 -0
  36. {git_nested-1.2.0 → git_nested-1.2.1}/.gitattributes +0 -0
  37. {git_nested-1.2.0 → git_nested-1.2.1}/.github/CODEOWNERS +0 -0
  38. {git_nested-1.2.0 → git_nested-1.2.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
  39. {git_nested-1.2.0 → git_nested-1.2.1}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  40. {git_nested-1.2.0 → git_nested-1.2.1}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
  41. {git_nested-1.2.0 → git_nested-1.2.1}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
  42. {git_nested-1.2.0 → git_nested-1.2.1}/.github/dependabot.yml +0 -0
  43. {git_nested-1.2.0 → git_nested-1.2.1}/.github/release.yml +0 -0
  44. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/build-binary.yml +0 -0
  45. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/prune-artifacts.yml +0 -0
  46. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/publish.yml +0 -0
  47. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/release-binary.yml +0 -0
  48. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/test-binary.yml +0 -0
  49. {git_nested-1.2.0 → git_nested-1.2.1}/.github/workflows/test.yml +0 -0
  50. {git_nested-1.2.0 → git_nested-1.2.1}/.gitignore +0 -0
  51. {git_nested-1.2.0 → git_nested-1.2.1}/.pre-commit-config.yaml +0 -0
  52. {git_nested-1.2.0 → git_nested-1.2.1}/.rc +0 -0
  53. {git_nested-1.2.0 → git_nested-1.2.1}/CONTRIBUTING.md +0 -0
  54. {git_nested-1.2.0 → git_nested-1.2.1}/LICENSE +0 -0
  55. {git_nested-1.2.0 → git_nested-1.2.1}/SECURITY.md +0 -0
  56. {git_nested-1.2.0 → git_nested-1.2.1}/bin/git-nested +0 -0
  57. {git_nested-1.2.0 → git_nested-1.2.1}/doc/_static/custom.js +0 -0
  58. {git_nested-1.2.0 → git_nested-1.2.1}/doc/_templates/layout.html +0 -0
  59. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/branch.md +0 -0
  60. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/clean.md +0 -0
  61. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/clone.md +0 -0
  62. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/commit.md +0 -0
  63. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/completion.md +0 -0
  64. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/config.md +0 -0
  65. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/diff.md +0 -0
  66. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/environment-variables.md +0 -0
  67. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/fetch.md +0 -0
  68. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/index.md +0 -0
  69. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/init.md +0 -0
  70. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/pull.md +0 -0
  71. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/push.md +0 -0
  72. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/repair.md +0 -0
  73. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/run.md +0 -0
  74. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/status.md +0 -0
  75. {git_nested-1.2.0 → git_nested-1.2.1}/doc/cli/version.md +0 -0
  76. {git_nested-1.2.0 → git_nested-1.2.1}/doc/concepts/comparison.md +0 -0
  77. {git_nested-1.2.0 → git_nested-1.2.1}/doc/concepts/how-it-works.md +0 -0
  78. {git_nested-1.2.0 → git_nested-1.2.1}/doc/contributing/development.md +0 -0
  79. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/adopt.md +0 -0
  80. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/conflicts.md +0 -0
  81. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/hooks-and-signing.md +0 -0
  82. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/many.md +0 -0
  83. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/nested-in-nested.md +0 -0
  84. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/partial.md +0 -0
  85. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/pin.md +0 -0
  86. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/squash-merges.md +0 -0
  87. {git_nested-1.2.0 → git_nested-1.2.1}/doc/guides/submodules.md +0 -0
  88. {git_nested-1.2.0 → git_nested-1.2.1}/doc/quickstart/05-minutes.md +0 -0
  89. {git_nested-1.2.0 → git_nested-1.2.1}/doc/quickstart/everyday.md +0 -0
  90. {git_nested-1.2.0 → git_nested-1.2.1}/man/man1/git-nested.1 +0 -0
  91. {git_nested-1.2.0 → git_nested-1.2.1}/pyproject.toml +0 -0
  92. {git_nested-1.2.0 → git_nested-1.2.1}/scripts/create-python-exe.sh +0 -0
  93. {git_nested-1.2.0 → git_nested-1.2.1}/setup.cfg +0 -0
  94. {git_nested-1.2.0 → git_nested-1.2.1}/sonar-project.properties +0 -0
  95. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/__init__.py +0 -0
  96. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/__main__.py +0 -0
  97. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/_compat.py +0 -0
  98. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/_version.py +0 -0
  99. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/checks.py +0 -0
  100. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/__init__.py +0 -0
  101. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/app.py +0 -0
  102. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/location.py +0 -0
  103. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/main.py +0 -0
  104. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/parser.py +0 -0
  105. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/cli/spec.py +0 -0
  106. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/__init__.py +0 -0
  107. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/branch.py +0 -0
  108. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/clean.py +0 -0
  109. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/clone.py +0 -0
  110. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/commit.py +0 -0
  111. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/completion.py +0 -0
  112. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/diff.py +0 -0
  113. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/fetch.py +0 -0
  114. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/init.py +0 -0
  115. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/pull.py +0 -0
  116. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/push.py +0 -0
  117. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/repair.py +0 -0
  118. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/run.py +0 -0
  119. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/status.py +0 -0
  120. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/commands/version.py +0 -0
  121. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/completion/__init__.py +0 -0
  122. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/completion/scripts.py +0 -0
  123. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/constants.py +0 -0
  124. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/content.py +0 -0
  125. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/discovery.py +0 -0
  126. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/errors.py +0 -0
  127. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/filters.py +0 -0
  128. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/git.py +0 -0
  129. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/messages.py +0 -0
  130. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/output.py +0 -0
  131. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/py.typed +0 -0
  132. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/refs.py +0 -0
  133. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/submodules.py +0 -0
  134. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested/worktree.py +0 -0
  135. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/dependency_links.txt +0 -0
  136. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/entry_points.txt +0 -0
  137. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/requires.txt +0 -0
  138. {git_nested-1.2.0 → git_nested-1.2.1}/src/git_nested.egg-info/top_level.txt +0 -0
  139. {git_nested-1.2.0 → git_nested-1.2.1}/tests/conftest.py +0 -0
  140. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/scenarios/test_extraction.py +0 -0
  141. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/scenarios/test_filemode.py +0 -0
  142. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/scenarios/test_filter.py +0 -0
  143. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_branch.py +0 -0
  144. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_clean.py +0 -0
  145. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_clone.py +0 -0
  146. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_commit.py +0 -0
  147. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_completion.py +0 -0
  148. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_config.py +0 -0
  149. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_detached.py +0 -0
  150. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_diff.py +0 -0
  151. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_encode.py +0 -0
  152. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_error.py +0 -0
  153. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_exclude.py +0 -0
  154. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_fetch.py +0 -0
  155. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_gitignore.py +0 -0
  156. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_init.py +0 -0
  157. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_nested_in_nested.py +0 -0
  158. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_non_ascii.py +0 -0
  159. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_pin.py +0 -0
  160. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_pull.py +0 -0
  161. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_push.py +0 -0
  162. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_rebase.py +0 -0
  163. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_reclone.py +0 -0
  164. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_repair.py +0 -0
  165. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_run.py +0 -0
  166. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_signing.py +0 -0
  167. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_status.py +0 -0
  168. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_subdirectory.py +0 -0
  169. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_submodule.py +0 -0
  170. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_submodules.py +0 -0
  171. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_upstream_path.py +0 -0
  172. {git_nested-1.2.0 → git_nested-1.2.1}/tests/e2e/test_version.py +0 -0
  173. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/conftest.py +0 -0
  174. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/fakes.py +0 -0
  175. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_adopt.py +0 -0
  176. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_command.py +0 -0
  177. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_completion_engine.py +0 -0
  178. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_docs.py +0 -0
  179. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_logging.py +0 -0
  180. {git_nested-1.2.0 → git_nested-1.2.1}/tests/unit/test_repo_business.py +0 -0
  181. {git_nested-1.2.0 → git_nested-1.2.1}/uv.lock +0 -0
@@ -1,11 +1,13 @@
1
1
  name: Docs
2
2
 
3
3
  # Builds doc/ (see doc/conf.py) with Sphinx. On pull requests it only
4
- # builds, so a broken page fails the check. On main it also publishes the
5
- # site to the gh_pages branch, which GitHub Pages serves.
4
+ # builds, so a broken page fails the check. On main and on a release tag it
5
+ # also publishes the site to the gh_pages branch, which GitHub Pages serves.
6
+ # A tag build shows the release version.
6
7
  on:
7
8
  push:
8
9
  branches: [main]
10
+ tags: ['*.*.*']
9
11
  pull_request:
10
12
  branches: ['**']
11
13
  # by hand: 'Run workflow' in the Actions tab, or `gh workflow run docs.yml`
@@ -34,7 +36,7 @@ jobs:
34
36
  - name: Build docs
35
37
  run: uv run poe docs
36
38
  - name: Upload docs
37
- if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
39
+ if: github.event_name != 'pull_request' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/'))
38
40
  uses: actions/upload-artifact@v7
39
41
  with:
40
42
  name: docs-html
@@ -42,10 +44,14 @@ jobs:
42
44
  include-hidden-files: true
43
45
 
44
46
  # A job of its own, so only this one can write to the repository.
45
- # Only main is published, also when the workflow is started by hand.
47
+ # Only main and tags are published, also when the workflow is started by hand.
46
48
  publish:
47
- if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
49
+ if: github.event_name != 'pull_request' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/'))
48
50
  needs: build
51
+ # One publish at a time: a tag and main are often pushed together.
52
+ concurrency:
53
+ group: gh-pages
54
+ cancel-in-progress: false
49
55
  runs-on: ubuntu-26.04
50
56
  permissions:
51
57
  contents: write
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: git-nested
3
- Version: 1.2.0
3
+ Version: 1.2.1
4
4
  Summary: Git Submodule Alternative
5
5
  Author-email: Thorsten Klein <thorsten.klein.git@gmail.com>
6
6
  License: MIT
@@ -26,6 +26,8 @@ Dynamic: license-file
26
26
 
27
27
  # git-nested
28
28
 
29
+ <img src="https://raw.githubusercontent.com/thorsten-klein/git-nested/main/doc/_static/logo.svg" alt="logo" width="500"/>
30
+
29
31
  > An alternative to git-submodule and git-subtree for managing nested repositories.
30
32
 
31
33
  [![Test](https://github.com/thorsten-klein/git-nested/actions/workflows/test.yml/badge.svg)](https://github.com/thorsten-klein/git-nested/actions/workflows/test.yml)
@@ -1,5 +1,7 @@
1
1
  # git-nested
2
2
 
3
+ <img src="https://raw.githubusercontent.com/thorsten-klein/git-nested/main/doc/_static/logo.svg" alt="logo" width="500"/>
4
+
3
5
  > An alternative to git-submodule and git-subtree for managing nested repositories.
4
6
 
5
7
  [![Test](https://github.com/thorsten-klein/git-nested/actions/workflows/test.yml/badge.svg)](https://github.com/thorsten-klein/git-nested/actions/workflows/test.yml)
@@ -37,6 +37,8 @@ on GitHub, or as a website at <https://thorsten-klein.github.io/git-nested/>.
37
37
 
38
38
  - **[`configuration/gitnested-file.md`](configuration/gitnested-file.md)**:
39
39
  every field of the `.gitnested` file.
40
+ - **[`configuration/examples.md`](configuration/examples.md)**: how
41
+ `.gitnested` looks in common cases, in YAML and TOML.
40
42
  - **[`configuration/git-config.md`](configuration/git-config.md)**: the
41
43
  `git config` settings git-nested reads and writes.
42
44
 
@@ -100,3 +100,12 @@
100
100
  color: #fcfcfc;
101
101
  text-decoration: underline;
102
102
  }
103
+
104
+ /* 6. The logo in the sidebar (html_logo in doc/conf.py). It has no
105
+ * background, so it needs a light one on the blue sidebar. */
106
+ .wy-side-nav-search .wy-dropdown > a img.logo,
107
+ .wy-side-nav-search > a img.logo {
108
+ background: #fcfcfc;
109
+ border-radius: 6px;
110
+ padding: 6px 10px;
111
+ }
@@ -0,0 +1,29 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="8 0 256 256" width="256" height="256" role="img" aria-label="git-nested">
2
+ <!-- outer commit tree -->
3
+ <g fill="none" stroke="#1B2330" stroke-width="10" stroke-linecap="round">
4
+ <path d="M64 40 V216"/>
5
+ <path d="M64 44 C 64 62, 160 48, 160 70"/>
6
+ <path d="M160 186 C 160 208, 64 194, 64 212"/>
7
+ </g>
8
+ <g fill="#1B2330">
9
+ <circle cx="64" cy="40" r="15"/>
10
+ <circle cx="64" cy="128" r="15"/>
11
+ <circle cx="64" cy="216" r="15"/>
12
+ </g>
13
+
14
+ <!-- the nested repo: a commit that is itself a commit tree -->
15
+ <circle cx="160" cy="128" r="58" fill="#E6F6F0" stroke="#12A67E" stroke-width="10"/>
16
+
17
+ <!-- inner commit tree -->
18
+ <g fill="none" stroke="#0E7C5F" stroke-width="6" stroke-linecap="round">
19
+ <path d="M138 100 V156"/>
20
+ <path d="M138 104 C 138 114, 180 106, 180 118"/>
21
+ <path d="M180 138 C 180 150, 138 142, 138 152"/>
22
+ </g>
23
+ <g fill="#0E7C5F">
24
+ <circle cx="138" cy="100" r="8"/>
25
+ <circle cx="138" cy="128" r="8"/>
26
+ <circle cx="138" cy="156" r="8"/>
27
+ </g>
28
+ <circle cx="180" cy="128" r="10" fill="#FFFFFF" stroke="#0E7C5F" stroke-width="5"/>
29
+ </svg>
@@ -0,0 +1,30 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 256" width="800" height="256" role="img" aria-label="git-nested">
2
+ <!-- outer commit tree -->
3
+ <g fill="none" stroke="#1B2330" stroke-width="10" stroke-linecap="round">
4
+ <path d="M64 40 V216"/>
5
+ <path d="M64 44 C 64 62, 160 48, 160 70"/>
6
+ <path d="M160 186 C 160 208, 64 194, 64 212"/>
7
+ </g>
8
+ <g fill="#1B2330">
9
+ <circle cx="64" cy="40" r="15"/>
10
+ <circle cx="64" cy="128" r="15"/>
11
+ <circle cx="64" cy="216" r="15"/>
12
+ </g>
13
+
14
+ <!-- the nested repo: a commit that is itself a commit tree -->
15
+ <circle cx="160" cy="128" r="58" fill="#E6F6F0" stroke="#12A67E" stroke-width="10"/>
16
+
17
+ <!-- inner commit tree -->
18
+ <g fill="none" stroke="#0E7C5F" stroke-width="6" stroke-linecap="round">
19
+ <path d="M138 100 V156"/>
20
+ <path d="M138 104 C 138 114, 180 106, 180 118"/>
21
+ <path d="M180 138 C 180 150, 138 142, 138 152"/>
22
+ </g>
23
+ <g fill="#0E7C5F">
24
+ <circle cx="138" cy="100" r="8"/>
25
+ <circle cx="138" cy="128" r="8"/>
26
+ <circle cx="138" cy="156" r="8"/>
27
+ </g>
28
+ <circle cx="180" cy="128" r="10" fill="#FFFFFF" stroke="#0E7C5F" stroke-width="5"/>
29
+ <text x="262" y="156" font-family="'JetBrains Mono', 'Fira Code', ui-monospace, Menlo, Consolas, monospace" font-size="84" letter-spacing="-2"><tspan fill="#5B6676" font-weight="400">git-</tspan><tspan fill="#1B2330" font-weight="800">nested</tspan></text>
30
+ </svg>
@@ -53,7 +53,7 @@ sequenceDiagram
53
53
  git-nested->>Git: ls-files -- <subdir>
54
54
  git-nested->>Git: log --format=%H %T <upstream_head>
55
55
  Note over git-nested: Find the newest upstream commit<br/>whose tree matches <subdir> at HEAD
56
- Note over git-nested: Write .gitnested YAML
56
+ Note over git-nested: Write .gitnested
57
57
  git-nested->>Git: rev-parse <matching_commit>
58
58
  git-nested->>Git: add -f -- <subdir>/.gitnested
59
59
  git-nested->>Git: commit --no-verify [--signoff] [-S] -m <message>
@@ -68,7 +68,7 @@ sequenceDiagram
68
68
  git-nested->>Git: merge-base --is-ancestor <upstream> <nested_ref>
69
69
  git-nested->>Git: ls-files -- <subdir>
70
70
  git-nested->>Git: read-tree --prefix=<subdir> -u <nested_commit_ref>
71
- Note over git-nested: Write .gitnested YAML
71
+ Note over git-nested: Write .gitnested
72
72
  git-nested->>Git: rev-parse <nested_commit_ref>
73
73
  git-nested->>Git: add -f -- <subdir>/.gitnested
74
74
  git-nested->>Git: diff --cached --quiet
@@ -132,7 +132,7 @@ sequenceDiagram
132
132
 
133
133
  rect rgb(230, 245, 255)
134
134
  Note over git-nested,Git: update_gitrepo_file
135
- Note over git-nested: Write .gitnested YAML
135
+ Note over git-nested: Write .gitnested
136
136
  git-nested->>Git: rev-parse <nested_commit_ref>
137
137
  git-nested->>Git: add -f -- <subdir>/.gitnested
138
138
  end
@@ -282,7 +282,7 @@ sequenceDiagram
282
282
  git-nested->>Git: ls-files -- <subdir>
283
283
  git-nested->>Git: rm -r -- <subdir>
284
284
  git-nested->>Git: read-tree --prefix=<subdir> -u <nested_commit_ref>
285
- Note over git-nested: Write .gitnested YAML
285
+ Note over git-nested: Write .gitnested
286
286
  git-nested->>Git: add -f -- <subdir>/.gitnested
287
287
  git-nested->>Git: diff --cached --quiet
288
288
  git-nested->>Git: commit --no-verify [--signoff] [-S] -m <message>
@@ -304,7 +304,7 @@ sequenceDiagram
304
304
  git-nested->>Git: ls-files -- <subdir>
305
305
  git-nested->>Git: rm -r -- <subdir>
306
306
  git-nested->>Git: read-tree --prefix=<subdir> -u <nested_commit_ref>
307
- Note over git-nested: Write .gitnested YAML
307
+ Note over git-nested: Write .gitnested
308
308
  git-nested->>Git: add -f -- <subdir>/.gitnested
309
309
  git-nested->>Git: commit --no-verify [--signoff] [-S] -m <message>
310
310
  git-nested->>Git: worktree prune
@@ -416,7 +416,7 @@ sequenceDiagram
416
416
  end
417
417
 
418
418
  opt --commit flag
419
- Note over git-nested: Update .gitnested YAML
419
+ Note over git-nested: Update .gitnested
420
420
  git-nested->>Git: add -f -- <subdir>/.gitnested
421
421
  git-nested->>Git: commit --no-verify [--signoff] [-S] -m <message>
422
422
  Note over git-nested: If it fails: reset -q --hard HEAD
@@ -652,7 +652,7 @@ sequenceDiagram
652
652
  git-nested->>Git: ls-files -- <subdir>
653
653
  git-nested->>Git: rm -r -- <subdir>
654
654
  git-nested->>Git: read-tree --prefix=<subdir> -u <nested_commit_ref>
655
- Note over git-nested: Write .gitnested YAML
655
+ Note over git-nested: Write .gitnested
656
656
  git-nested->>Git: rev-parse <nested_commit_ref>
657
657
  git-nested->>Git: add -f -- <subdir>/.gitnested
658
658
  git-nested->>Git: diff --cached --quiet
@@ -79,7 +79,7 @@ One module per command, for example `commands/pull.py`. Each has one
79
79
  | `output.py` | everything git-nested prints; hides credentials |
80
80
  | `messages.py` | the long help texts, for example after a conflict |
81
81
  | `models.py` | `Flags`, `NestedConfig`, `CommandContext` |
82
- | `yamlio.py` | reads and writes the YAML of `.gitnested` |
82
+ | `configio.py` | reads and writes `.gitnested`, as YAML or TOML |
83
83
  | `errors.py` | `GitNestedError`, the one exception type |
84
84
  | `constants.py` | shared names |
85
85
  | `_version.py` | the version |
@@ -3,7 +3,7 @@
3
3
  The words this documentation uses, in alphabetical order.
4
4
 
5
5
  **`.gitnested` file**
6
- : A small YAML file in each nested folder. It records the upstream, the
6
+ : A small YAML or TOML file in each nested folder. It records the upstream, the
7
7
  branch, the upstream commit and the sync point. It is committed to your
8
8
  repository, but never pushed upstream. See
9
9
  [The `.gitnested` file](../configuration/gitnested-file.md).
@@ -82,6 +82,10 @@ html_static_path = ['_static']
82
82
  html_css_files = ['custom.css']
83
83
  html_js_files = ['custom.js']
84
84
 
85
+ # The logo on top of the sidebar. The browser tab shows only its mark.
86
+ html_logo = '_static/logo.svg'
87
+ html_favicon = '_static/favicon.svg'
88
+
85
89
  html_theme_options = {
86
90
  'collapse_navigation': False,
87
91
  'navigation_depth': 3,
@@ -0,0 +1,259 @@
1
+ # `.gitnested` examples
2
+
3
+ This page shows how `.gitnested` looks in common cases. Each example comes
4
+ in YAML and in TOML. Both mean the same.
5
+
6
+ - YAML is the default.
7
+ - TOML needs Python 3.11 or newer. See
8
+ [The `.gitnested` file](gitnested-file.md#toml).
9
+ - [The `.gitnested` file](gitnested-file.md) explains every field.
10
+
11
+ git-nested writes most fields itself. You set the others with
12
+ [`git nested config`](../cli/config.md) or with options of `clone`.
13
+
14
+ ## After a clone
15
+
16
+ ```bash
17
+ git nested clone https://github.com/user/lib ext/lib
18
+ ```
19
+
20
+ YAML:
21
+
22
+ ```yaml
23
+ # This subdirectory is managed by "git nested".
24
+ # Refer to: https://github.com/thorsten-klein/git-nested#readme
25
+ #
26
+ nested:
27
+ commit: 401b344cd6917389538657fa06cd5f007dfb664c
28
+ method: merge
29
+ cmdver: 1.1.1
30
+ remote: https://github.com/user/lib
31
+ branch: main
32
+ parent: b2dfdc71d112c5e7102726c32c323901a9457630
33
+ ```
34
+
35
+ TOML:
36
+
37
+ ```toml
38
+ # This subdirectory is managed by "git nested".
39
+ # Refer to: https://github.com/thorsten-klein/git-nested#readme
40
+ #
41
+ [nested]
42
+ commit = "401b344cd6917389538657fa06cd5f007dfb664c"
43
+ method = "merge"
44
+ cmdver = "1.1.1"
45
+ remote = "https://github.com/user/lib"
46
+ branch = "main"
47
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
48
+ ```
49
+
50
+ The examples below leave out the comment lines on top.
51
+
52
+ ## The smallest file
53
+
54
+ Only `remote` and `branch` are needed. git-nested fills in the rest on the
55
+ next pull.
56
+
57
+ YAML:
58
+
59
+ ```yaml
60
+ nested:
61
+ remote: https://github.com/user/lib
62
+ branch: main
63
+ ```
64
+
65
+ TOML:
66
+
67
+ ```toml
68
+ [nested]
69
+ remote = "https://github.com/user/lib"
70
+ branch = "main"
71
+ ```
72
+
73
+ ## No upstream yet
74
+
75
+ ```bash
76
+ git nested init ext/lib
77
+ ```
78
+
79
+ `init` without `-r` writes the remote `none`. Set the real remote later
80
+ with `git nested config ext/lib remote <url>`.
81
+
82
+ YAML:
83
+
84
+ ```yaml
85
+ nested:
86
+ commit: ''
87
+ method: merge
88
+ cmdver: 1.1.1
89
+ remote: none
90
+ branch: main
91
+ ```
92
+
93
+ TOML:
94
+
95
+ ```toml
96
+ [nested]
97
+ commit = ""
98
+ method = "merge"
99
+ cmdver = "1.1.1"
100
+ remote = "none"
101
+ branch = "main"
102
+ ```
103
+
104
+ ## Rebase, keep the upstream commits, never push
105
+
106
+ ```bash
107
+ git nested clone --rebase https://github.com/user/lib ext/lib
108
+ git nested config ext/lib squash false
109
+ git nested config ext/lib readonly true
110
+ ```
111
+
112
+ - `method: rebase` puts your changes on top of upstream.
113
+ - `squash: false` keeps the upstream commits in your history.
114
+ - `readonly: true` makes `push` refuse.
115
+
116
+ YAML:
117
+
118
+ ```yaml
119
+ nested:
120
+ commit: 401b344cd6917389538657fa06cd5f007dfb664c
121
+ method: rebase
122
+ cmdver: 1.1.1
123
+ remote: https://github.com/user/lib
124
+ branch: main
125
+ parent: b2dfdc71d112c5e7102726c32c323901a9457630
126
+ squash: 'false'
127
+ readonly: 'true'
128
+ ```
129
+
130
+ TOML:
131
+
132
+ ```toml
133
+ [nested]
134
+ commit = "401b344cd6917389538657fa06cd5f007dfb664c"
135
+ method = "rebase"
136
+ cmdver = "1.1.1"
137
+ remote = "https://github.com/user/lib"
138
+ branch = "main"
139
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
140
+ squash = "false"
141
+ readonly = "true"
142
+ ```
143
+
144
+ `true` and `false` also work without quotes.
145
+
146
+ ## Only a part of upstream
147
+
148
+ ```bash
149
+ git nested clone --filter src --filter 'docs/.*\.md' --exclude src/tests https://github.com/user/lib ext/lib
150
+ ```
151
+
152
+ - `filter` lists what to take. A regular expression must match the whole
153
+ path.
154
+ - `exclude` lists what to leave out.
155
+
156
+ YAML:
157
+
158
+ ```yaml
159
+ nested:
160
+ commit: 401b344cd6917389538657fa06cd5f007dfb664c
161
+ method: merge
162
+ cmdver: 1.1.1
163
+ filter:
164
+ - src
165
+ - docs/.*\.md
166
+ exclude:
167
+ - src/tests
168
+ remote: https://github.com/user/lib
169
+ branch: main
170
+ parent: b2dfdc71d112c5e7102726c32c323901a9457630
171
+ ```
172
+
173
+ TOML:
174
+
175
+ ```toml
176
+ [nested]
177
+ commit = "401b344cd6917389538657fa06cd5f007dfb664c"
178
+ method = "merge"
179
+ cmdver = "1.1.1"
180
+ filter = ["src", "docs/.*\\.md"]
181
+ exclude = ["src/tests"]
182
+ remote = "https://github.com/user/lib"
183
+ branch = "main"
184
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
185
+ ```
186
+
187
+ In a TOML string, `\` is written `\\`.
188
+
189
+ See [Nest only a part of upstream](../guides/partial.md).
190
+
191
+ ## One folder of upstream
192
+
193
+ ```bash
194
+ git nested clone --path lib/python https://github.com/user/monorepo ext/lib
195
+ ```
196
+
197
+ The content of `lib/python` is at the top of `ext/lib`.
198
+
199
+ YAML:
200
+
201
+ ```yaml
202
+ nested:
203
+ commit: 401b344cd6917389538657fa06cd5f007dfb664c
204
+ method: merge
205
+ cmdver: 1.1.1
206
+ path: lib/python
207
+ remote: https://github.com/user/monorepo
208
+ branch: main
209
+ parent: b2dfdc71d112c5e7102726c32c323901a9457630
210
+ ```
211
+
212
+ TOML:
213
+
214
+ ```toml
215
+ [nested]
216
+ commit = "401b344cd6917389538657fa06cd5f007dfb664c"
217
+ method = "merge"
218
+ cmdver = "1.1.1"
219
+ path = "lib/python"
220
+ remote = "https://github.com/user/monorepo"
221
+ branch = "main"
222
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
223
+ ```
224
+
225
+ ## Pinned to a release
226
+
227
+ ```bash
228
+ git nested clone --pin v2.1.0 https://github.com/user/lib ext/lib
229
+ ```
230
+
231
+ A pull stays at `v2.1.0`. `git nested pull ext/lib --pin v2.2.0` moves on.
232
+
233
+ YAML:
234
+
235
+ ```yaml
236
+ nested:
237
+ commit: 9a38b6d7c1e04f2b8d5a6e3f1c2b4a7d8e9f0a1b
238
+ method: merge
239
+ cmdver: 1.1.1
240
+ pin: v2.1.0
241
+ remote: https://github.com/user/lib
242
+ branch: main
243
+ parent: b2dfdc71d112c5e7102726c32c323901a9457630
244
+ ```
245
+
246
+ TOML:
247
+
248
+ ```toml
249
+ [nested]
250
+ commit = "9a38b6d7c1e04f2b8d5a6e3f1c2b4a7d8e9f0a1b"
251
+ method = "merge"
252
+ cmdver = "1.1.1"
253
+ pin = "v2.1.0"
254
+ remote = "https://github.com/user/lib"
255
+ branch = "main"
256
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
257
+ ```
258
+
259
+ See [Pin a release](../guides/pin.md).
@@ -17,6 +17,17 @@ commits. Those hooks are for your changes, not for upstream content.
17
17
 
18
18
  See [Hooks and signing](../guides/hooks-and-signing.md).
19
19
 
20
+ ### `nested.format`
21
+
22
+ ```bash
23
+ git config nested.format toml
24
+ ```
25
+
26
+ The format of new `.gitnested` files: `yaml` (the default) or `toml`. TOML
27
+ needs Python 3.11 or newer. Files that exist keep their format.
28
+
29
+ See [The `.gitnested` file](gitnested-file.md#toml).
30
+
20
31
  ### `user.signingKey`
21
32
 
22
33
  git's own setting. `-S` uses it to pick the GPG key.
@@ -5,11 +5,13 @@ the content comes from, and how far it is in step with upstream.
5
5
 
6
6
  - It is committed to your repository.
7
7
  - It is never pushed upstream.
8
- - It is YAML. All fields sit under `nested:`.
8
+ - It is YAML or TOML. All fields sit under `nested`.
9
9
 
10
10
  Read and change it with [`git nested config`](../cli/config.md), not by
11
11
  hand.
12
12
 
13
+ See [`.gitnested` examples](examples.md) for more examples.
14
+
13
15
  ## Example
14
16
 
15
17
  ```yaml
@@ -25,6 +27,31 @@ nested:
25
27
  parent: b2dfdc71d112c5e7102726c32c323901a9457630
26
28
  ```
27
29
 
30
+ ## TOML
31
+
32
+ With Python 3.11 or newer, `.gitnested` can also be TOML:
33
+
34
+ ```toml
35
+ # This subdirectory is managed by "git nested".
36
+ # Refer to: https://github.com/thorsten-klein/git-nested#readme
37
+ #
38
+ [nested]
39
+ commit = "401b344cd6917389538657fa06cd5f007dfb664c"
40
+ method = "merge"
41
+ cmdver = "1.1.1"
42
+ remote = "https://github.com/user/lib"
43
+ branch = "main"
44
+ parent = "b2dfdc71d112c5e7102726c32c323901a9457630"
45
+ ```
46
+
47
+ - A file with a `[nested]` line is TOML. Any other file is YAML.
48
+ - git-nested keeps the format of a file when it writes it.
49
+ - New files are YAML. Set [`nested.format`](git-config.md#nestedformat) to
50
+ `toml` to get TOML instead.
51
+ - Python 3.10 cannot read TOML. There, git-nested stops with an error.
52
+
53
+ You can turn a YAML file into TOML by hand. The fields stay the same.
54
+
28
55
  ## Fields
29
56
 
30
57
  Fields that are not set take their default.
@@ -74,6 +74,9 @@ The pages are GitHub Markdown, read by [MyST](https://myst-parser.readthedocs.io
74
74
  push to `main`, it also publishes the site to the `gh_pages` branch. GitHub
75
75
  Pages serves it at <https://thorsten-klein.github.io/git-nested/>.
76
76
 
77
+ A release tag like `1.2.0` publishes the site again. Then the site shows
78
+ the release version.
79
+
77
80
  To publish by hand, start the workflow in the Actions tab, or run:
78
81
 
79
82
  ```bash
@@ -1,5 +1,7 @@
1
1
  # git-nested
2
2
 
3
+ <img src="https://raw.githubusercontent.com/thorsten-klein/git-nested/main/doc/_static/logo.svg" alt="git-nested logo" width="500"/>
4
+
3
5
  Put another repository into a folder of yours. Pull its new changes. Push
4
6
  your changes back.
5
7
 
@@ -113,6 +115,7 @@ cli/environment-variables
113
115
  What git-nested stores, and where.
114
116
 
115
117
  - [The `.gitnested` file](configuration/gitnested-file.md)
118
+ - [`.gitnested` examples](configuration/examples.md)
116
119
  - [git config settings](configuration/git-config.md)
117
120
 
118
121
  ```{toctree}
@@ -121,6 +124,7 @@ What git-nested stores, and where.
121
124
  :hidden:
122
125
 
123
126
  configuration/gitnested-file
127
+ configuration/examples
124
128
  configuration/git-config
125
129
  ```
126
130
 
@@ -1,5 +1,7 @@
1
1
  # About git-nested
2
2
 
3
+ <img src="https://raw.githubusercontent.com/thorsten-klein/git-nested/main/doc/_static/logo.svg" alt="git-nested logo" width="500"/>
4
+
3
5
  git-nested puts another git repository into a folder of your repository.
4
6
  The files are ordinary files in ordinary commits. You can still pull new
5
7
  changes from the other repository, and push your changes back to it.
@@ -13,6 +13,7 @@
13
13
  | [Standalone executable](#standalone-executable) | Machines without Python |
14
14
  | [From source, with shell setup](#from-source-with-shell-setup) | Working on git-nested |
15
15
  | [From source, by hand](#from-source-by-hand) | Full control |
16
+ | [From source, editable mode](#from-source-editable-mode) | Using your own changes everywhere |
16
17
 
17
18
  After the install, `git nested` works like any git command. git finds it
18
19
  because the program is called `git-nested` and is on your `PATH`.
@@ -106,6 +107,22 @@ export PATH="/path/to/git-nested/bin:$PATH"
106
107
  Add the `export` line to your shell profile (`~/.bashrc`, `~/.zshrc`) to
107
108
  keep it.
108
109
 
110
+ ### From source, editable mode
111
+
112
+ This installs git-nested from your clone. Changes to the code work right
113
+ away. You do not have to install again.
114
+
115
+ ```bash
116
+ git clone https://github.com/thorsten-klein/git-nested /path/to/git-nested
117
+ pip install -e /path/to/git-nested
118
+ ```
119
+
120
+ Or as a tool of its own, with `uv`:
121
+
122
+ ```bash
123
+ uv tool install --editable /path/to/git-nested
124
+ ```
125
+
109
126
  ## Shell completion
110
127
 
111
128
  The shell setup from source turns completion on for you. For any other way,
@@ -69,6 +69,9 @@ def setup_command(
69
69
 
70
70
  # clone and init have no .gitnested yet. clean does not need it.
71
71
  if command in ['clone', 'init', 'clean']:
72
+ # Check nested.format now, not after the content is in place.
73
+ if command != 'clean':
74
+ gitfile.new_file_is_toml(git)
72
75
  config = NestedConfig(remote=flags.remote or upstream or '', branch=flags.branch or '', pin=flags.pin or '')
73
76
  else:
74
77
  config = gitfile.read_config(gitnested, flags)