ma-agents 2.20.1 → 2.20.2

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 (197) hide show
  1. package/README.md +55 -1
  2. package/lib/agents.js +22 -11
  3. package/lib/bmad-cache/bmb/_git_preserved/HEAD +1 -0
  4. package/lib/bmad-cache/bmb/_git_preserved/config +13 -0
  5. package/lib/bmad-cache/bmb/_git_preserved/description +1 -0
  6. package/lib/bmad-cache/bmb/_git_preserved/hooks/applypatch-msg.sample +15 -0
  7. package/lib/bmad-cache/bmb/_git_preserved/hooks/commit-msg.sample +24 -0
  8. package/lib/bmad-cache/bmb/_git_preserved/hooks/fsmonitor-watchman.sample +174 -0
  9. package/lib/bmad-cache/bmb/_git_preserved/hooks/post-update.sample +8 -0
  10. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-applypatch.sample +14 -0
  11. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-commit.sample +49 -0
  12. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-merge-commit.sample +13 -0
  13. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-push.sample +53 -0
  14. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-rebase.sample +169 -0
  15. package/lib/bmad-cache/bmb/_git_preserved/hooks/pre-receive.sample +24 -0
  16. package/lib/bmad-cache/bmb/_git_preserved/hooks/prepare-commit-msg.sample +42 -0
  17. package/lib/bmad-cache/bmb/_git_preserved/hooks/push-to-checkout.sample +78 -0
  18. package/lib/bmad-cache/bmb/_git_preserved/hooks/sendemail-validate.sample +77 -0
  19. package/lib/bmad-cache/bmb/_git_preserved/hooks/update.sample +128 -0
  20. package/lib/bmad-cache/bmb/_git_preserved/index +0 -0
  21. package/lib/bmad-cache/bmb/_git_preserved/info/exclude +6 -0
  22. package/lib/bmad-cache/bmb/_git_preserved/logs/HEAD +1 -0
  23. package/lib/bmad-cache/bmb/_git_preserved/logs/refs/heads/main +1 -0
  24. package/lib/bmad-cache/bmb/_git_preserved/logs/refs/remotes/origin/HEAD +1 -0
  25. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.idx +0 -0
  26. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.pack +0 -0
  27. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.rev +0 -0
  28. package/lib/bmad-cache/bmb/_git_preserved/packed-refs +2 -0
  29. package/lib/bmad-cache/bmb/_git_preserved/refs/heads/main +1 -0
  30. package/lib/bmad-cache/bmb/_git_preserved/refs/remotes/origin/HEAD +1 -0
  31. package/lib/bmad-cache/bmb/_git_preserved/shallow +1 -0
  32. package/lib/bmad-cache/cache-manifest.json +6 -6
  33. package/lib/bmad-cache/cis/_git_preserved/HEAD +1 -0
  34. package/lib/bmad-cache/cis/_git_preserved/config +13 -0
  35. package/lib/bmad-cache/cis/_git_preserved/description +1 -0
  36. package/lib/bmad-cache/cis/_git_preserved/hooks/applypatch-msg.sample +15 -0
  37. package/lib/bmad-cache/cis/_git_preserved/hooks/commit-msg.sample +24 -0
  38. package/lib/bmad-cache/cis/_git_preserved/hooks/fsmonitor-watchman.sample +174 -0
  39. package/lib/bmad-cache/cis/_git_preserved/hooks/post-update.sample +8 -0
  40. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-applypatch.sample +14 -0
  41. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-commit.sample +49 -0
  42. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-merge-commit.sample +13 -0
  43. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-push.sample +53 -0
  44. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-rebase.sample +169 -0
  45. package/lib/bmad-cache/cis/_git_preserved/hooks/pre-receive.sample +24 -0
  46. package/lib/bmad-cache/cis/_git_preserved/hooks/prepare-commit-msg.sample +42 -0
  47. package/lib/bmad-cache/cis/_git_preserved/hooks/push-to-checkout.sample +78 -0
  48. package/lib/bmad-cache/cis/_git_preserved/hooks/sendemail-validate.sample +77 -0
  49. package/lib/bmad-cache/cis/_git_preserved/hooks/update.sample +128 -0
  50. package/lib/bmad-cache/cis/_git_preserved/index +0 -0
  51. package/lib/bmad-cache/cis/_git_preserved/info/exclude +6 -0
  52. package/lib/bmad-cache/cis/_git_preserved/logs/HEAD +1 -0
  53. package/lib/bmad-cache/cis/_git_preserved/logs/refs/heads/main +1 -0
  54. package/lib/bmad-cache/cis/_git_preserved/logs/refs/remotes/origin/HEAD +1 -0
  55. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.idx +0 -0
  56. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.pack +0 -0
  57. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.rev +0 -0
  58. package/lib/bmad-cache/cis/_git_preserved/packed-refs +2 -0
  59. package/lib/bmad-cache/cis/_git_preserved/refs/heads/main +1 -0
  60. package/lib/bmad-cache/cis/_git_preserved/refs/remotes/origin/HEAD +1 -0
  61. package/lib/bmad-cache/cis/_git_preserved/shallow +1 -0
  62. package/lib/bmad-cache/gds/_git_preserved/HEAD +1 -0
  63. package/lib/bmad-cache/gds/_git_preserved/config +13 -0
  64. package/lib/bmad-cache/gds/_git_preserved/description +1 -0
  65. package/lib/bmad-cache/gds/_git_preserved/hooks/applypatch-msg.sample +15 -0
  66. package/lib/bmad-cache/gds/_git_preserved/hooks/commit-msg.sample +24 -0
  67. package/lib/bmad-cache/gds/_git_preserved/hooks/fsmonitor-watchman.sample +174 -0
  68. package/lib/bmad-cache/gds/_git_preserved/hooks/post-update.sample +8 -0
  69. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-applypatch.sample +14 -0
  70. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-commit.sample +49 -0
  71. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-merge-commit.sample +13 -0
  72. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-push.sample +53 -0
  73. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-rebase.sample +169 -0
  74. package/lib/bmad-cache/gds/_git_preserved/hooks/pre-receive.sample +24 -0
  75. package/lib/bmad-cache/gds/_git_preserved/hooks/prepare-commit-msg.sample +42 -0
  76. package/lib/bmad-cache/gds/_git_preserved/hooks/push-to-checkout.sample +78 -0
  77. package/lib/bmad-cache/gds/_git_preserved/hooks/sendemail-validate.sample +77 -0
  78. package/lib/bmad-cache/gds/_git_preserved/hooks/update.sample +128 -0
  79. package/lib/bmad-cache/gds/_git_preserved/index +0 -0
  80. package/lib/bmad-cache/gds/_git_preserved/info/exclude +6 -0
  81. package/lib/bmad-cache/gds/_git_preserved/logs/HEAD +1 -0
  82. package/lib/bmad-cache/gds/_git_preserved/logs/refs/heads/main +1 -0
  83. package/lib/bmad-cache/gds/_git_preserved/logs/refs/remotes/origin/HEAD +1 -0
  84. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.idx +0 -0
  85. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.pack +0 -0
  86. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.rev +0 -0
  87. package/lib/bmad-cache/gds/_git_preserved/packed-refs +2 -0
  88. package/lib/bmad-cache/gds/_git_preserved/refs/heads/main +1 -0
  89. package/lib/bmad-cache/gds/_git_preserved/refs/remotes/origin/HEAD +1 -0
  90. package/lib/bmad-cache/gds/_git_preserved/refs/tags/v0.2.2 +1 -0
  91. package/lib/bmad-cache/gds/_git_preserved/shallow +1 -0
  92. package/lib/bmad-cache/gds/package.json +2 -4
  93. package/lib/bmad-cache/gds/src/agents/gds-agent-game-architect/bmad-skill-manifest.yaml +11 -0
  94. package/lib/bmad-cache/gds/src/agents/gds-agent-game-designer/bmad-skill-manifest.yaml +11 -0
  95. package/lib/bmad-cache/gds/src/agents/gds-agent-game-dev/bmad-skill-manifest.yaml +11 -0
  96. package/lib/bmad-cache/gds/src/agents/gds-agent-game-qa/bmad-skill-manifest.yaml +11 -0
  97. package/lib/bmad-cache/gds/src/agents/gds-agent-game-scrum-master/bmad-skill-manifest.yaml +11 -0
  98. package/lib/bmad-cache/gds/src/agents/gds-agent-game-solo-dev/bmad-skill-manifest.yaml +11 -0
  99. package/lib/bmad-cache/gds/src/agents/gds-agent-tech-writer/bmad-skill-manifest.yaml +11 -0
  100. package/lib/bmad-cache/gds/src/module-help.csv +28 -28
  101. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-brainstorm-game/bmad-skill-manifest.yaml +1 -0
  102. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-create-game-brief/bmad-skill-manifest.yaml +1 -0
  103. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-gdd/bmad-skill-manifest.yaml +1 -0
  104. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-narrative/bmad-skill-manifest.yaml +1 -0
  105. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-check-implementation-readiness/bmad-skill-manifest.yaml +1 -0
  106. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-create-epics-and-stories/bmad-skill-manifest.yaml +1 -0
  107. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-game-architecture/bmad-skill-manifest.yaml +1 -0
  108. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-generate-project-context/bmad-skill-manifest.yaml +1 -0
  109. package/lib/bmad-cache/gds/src/workflows/4-production/gds-code-review/bmad-skill-manifest.yaml +1 -0
  110. package/lib/bmad-cache/gds/src/workflows/4-production/gds-correct-course/bmad-skill-manifest.yaml +1 -0
  111. package/lib/bmad-cache/gds/src/workflows/4-production/gds-retrospective/bmad-skill-manifest.yaml +1 -0
  112. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-planning/bmad-skill-manifest.yaml +1 -0
  113. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-status/bmad-skill-manifest.yaml +1 -0
  114. package/lib/bmad-cache/gds/src/workflows/gametest/gds-e2e-scaffold/bmad-skill-manifest.yaml +1 -0
  115. package/lib/bmad-cache/gds/src/workflows/gametest/gds-performance-test/bmad-skill-manifest.yaml +1 -0
  116. package/lib/bmad-cache/gds/src/workflows/gametest/gds-playtest-plan/bmad-skill-manifest.yaml +1 -0
  117. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-automate/bmad-skill-manifest.yaml +1 -0
  118. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-design/bmad-skill-manifest.yaml +1 -0
  119. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-framework/bmad-skill-manifest.yaml +1 -0
  120. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-review/bmad-skill-manifest.yaml +1 -0
  121. package/lib/bmad-cache/gds/src/workflows/gds-document-project/bmad-skill-manifest.yaml +1 -0
  122. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-dev/bmad-skill-manifest.yaml +1 -4
  123. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-dev-new-preview/bmad-skill-manifest.yaml +1 -4
  124. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-spec/bmad-skill-manifest.yaml +1 -0
  125. package/lib/bmad-cache/tea/_git_preserved/HEAD +1 -0
  126. package/lib/bmad-cache/tea/_git_preserved/config +13 -0
  127. package/lib/bmad-cache/tea/_git_preserved/description +1 -0
  128. package/lib/bmad-cache/tea/_git_preserved/hooks/applypatch-msg.sample +15 -0
  129. package/lib/bmad-cache/tea/_git_preserved/hooks/commit-msg.sample +24 -0
  130. package/lib/bmad-cache/tea/_git_preserved/hooks/fsmonitor-watchman.sample +174 -0
  131. package/lib/bmad-cache/tea/_git_preserved/hooks/post-update.sample +8 -0
  132. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-applypatch.sample +14 -0
  133. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-commit.sample +49 -0
  134. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-merge-commit.sample +13 -0
  135. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-push.sample +53 -0
  136. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-rebase.sample +169 -0
  137. package/lib/bmad-cache/tea/_git_preserved/hooks/pre-receive.sample +24 -0
  138. package/lib/bmad-cache/tea/_git_preserved/hooks/prepare-commit-msg.sample +42 -0
  139. package/lib/bmad-cache/tea/_git_preserved/hooks/push-to-checkout.sample +78 -0
  140. package/lib/bmad-cache/tea/_git_preserved/hooks/sendemail-validate.sample +77 -0
  141. package/lib/bmad-cache/tea/_git_preserved/hooks/update.sample +128 -0
  142. package/lib/bmad-cache/tea/_git_preserved/index +0 -0
  143. package/lib/bmad-cache/tea/_git_preserved/info/exclude +6 -0
  144. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.idx +0 -0
  145. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.pack +0 -0
  146. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.rev +0 -0
  147. package/lib/bmad-cache/tea/_git_preserved/packed-refs +2 -0
  148. package/lib/bmad-cache/tea/_git_preserved/refs/heads/main +1 -0
  149. package/lib/bmad-cache/tea/_git_preserved/refs/remotes/origin/HEAD +1 -0
  150. package/lib/bmad-cache/tea/_git_preserved/refs/tags/v1.7.0 +1 -0
  151. package/lib/bmad-cache/tea/_git_preserved/shallow +1 -0
  152. package/lib/bmad.js +33 -0
  153. package/lib/installer.js +60 -3
  154. package/package.json +1 -1
  155. package/scripts/build-bmad-cache.js +6 -3
  156. package/test/agent-injection-strategy.test.js +123 -0
  157. package/test/instruction-injection.test.js +336 -0
  158. package/lib/bmad-cache/gds/src/agents/game-architect.agent.yaml +0 -44
  159. package/lib/bmad-cache/gds/src/agents/game-designer.agent.yaml +0 -45
  160. package/lib/bmad-cache/gds/src/agents/game-dev.agent.yaml +0 -49
  161. package/lib/bmad-cache/gds/src/agents/game-qa.agent.yaml +0 -63
  162. package/lib/bmad-cache/gds/src/agents/game-scrum-master.agent.yaml +0 -52
  163. package/lib/bmad-cache/gds/src/agents/game-solo-dev.agent.yaml +0 -53
  164. package/lib/bmad-cache/gds/src/agents/tech-writer/tech-writer.agent.yaml +0 -45
  165. package/lib/bmad-cache/gds/src/teams/default-party.csv +0 -12
  166. package/lib/bmad-cache/gds/src/teams/team-gamedev.yaml +0 -29
  167. package/lib/bmad-cache/gds/src/workflows/1-preproduction/brainstorm-game/bmad-skill-manifest.yaml +0 -3
  168. package/lib/bmad-cache/gds/src/workflows/1-preproduction/game-brief/bmad-skill-manifest.yaml +0 -3
  169. package/lib/bmad-cache/gds/src/workflows/2-design/gdd/bmad-skill-manifest.yaml +0 -3
  170. package/lib/bmad-cache/gds/src/workflows/2-design/narrative/bmad-skill-manifest.yaml +0 -3
  171. package/lib/bmad-cache/gds/src/workflows/3-technical/check-implementation-readiness/bmad-skill-manifest.yaml +0 -3
  172. package/lib/bmad-cache/gds/src/workflows/3-technical/create-epics-and-stories/bmad-skill-manifest.yaml +0 -3
  173. package/lib/bmad-cache/gds/src/workflows/3-technical/game-architecture/bmad-skill-manifest.yaml +0 -3
  174. package/lib/bmad-cache/gds/src/workflows/3-technical/generate-project-context/bmad-skill-manifest.yaml +0 -3
  175. package/lib/bmad-cache/gds/src/workflows/4-production/code-review/bmad-skill-manifest.yaml +0 -3
  176. package/lib/bmad-cache/gds/src/workflows/4-production/correct-course/bmad-skill-manifest.yaml +0 -3
  177. package/lib/bmad-cache/gds/src/workflows/4-production/retrospective/bmad-skill-manifest.yaml +0 -3
  178. package/lib/bmad-cache/gds/src/workflows/4-production/sprint-planning/bmad-skill-manifest.yaml +0 -3
  179. package/lib/bmad-cache/gds/src/workflows/4-production/sprint-status/bmad-skill-manifest.yaml +0 -3
  180. package/lib/bmad-cache/gds/src/workflows/document-project/bmad-skill-manifest.yaml +0 -3
  181. package/lib/bmad-cache/gds/src/workflows/gametest/automate/bmad-skill-manifest.yaml +0 -3
  182. package/lib/bmad-cache/gds/src/workflows/gametest/e2e-scaffold/bmad-skill-manifest.yaml +0 -3
  183. package/lib/bmad-cache/gds/src/workflows/gametest/performance/bmad-skill-manifest.yaml +0 -3
  184. package/lib/bmad-cache/gds/src/workflows/gametest/playtest-plan/bmad-skill-manifest.yaml +0 -3
  185. package/lib/bmad-cache/gds/src/workflows/gametest/test-design/bmad-skill-manifest.yaml +0 -3
  186. package/lib/bmad-cache/gds/src/workflows/gametest/test-framework/bmad-skill-manifest.yaml +0 -3
  187. package/lib/bmad-cache/gds/src/workflows/gametest/test-review/bmad-skill-manifest.yaml +0 -3
  188. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/quick-spec/bmad-skill-manifest.yaml +0 -3
  189. /package/lib/bmad-cache/gds/src/workflows/1-preproduction/{brainstorm-game → gds-brainstorm-game}/game-brain-methods.csv +0 -0
  190. /package/lib/bmad-cache/gds/src/workflows/2-design/{gdd → gds-create-gdd}/game-types.csv +0 -0
  191. /package/lib/bmad-cache/gds/src/workflows/3-technical/{game-architecture → gds-game-architecture}/architecture-patterns.yaml +0 -0
  192. /package/lib/bmad-cache/gds/src/workflows/3-technical/{game-architecture → gds-game-architecture}/decision-catalog.yaml +0 -0
  193. /package/lib/bmad-cache/gds/src/workflows/3-technical/{game-architecture → gds-game-architecture}/engine-mcps.yaml +0 -0
  194. /package/lib/bmad-cache/gds/src/workflows/3-technical/{game-architecture → gds-game-architecture}/pattern-categories.csv +0 -0
  195. /package/lib/bmad-cache/gds/src/workflows/4-production/{sprint-planning → gds-sprint-planning}/sprint-status-template.yaml +0 -0
  196. /package/lib/bmad-cache/gds/src/workflows/{document-project → gds-document-project}/documentation-requirements.csv +0 -0
  197. /package/lib/bmad-cache/gds/src/workflows/{document-project → gds-document-project}/templates/project-scan-report-schema.json +0 -0
@@ -0,0 +1,77 @@
1
+ #!/bin/sh
2
+
3
+ # An example hook script to validate a patch (and/or patch series) before
4
+ # sending it via email.
5
+ #
6
+ # The hook should exit with non-zero status after issuing an appropriate
7
+ # message if it wants to prevent the email(s) from being sent.
8
+ #
9
+ # To enable this hook, rename this file to "sendemail-validate".
10
+ #
11
+ # By default, it will only check that the patch(es) can be applied on top of
12
+ # the default upstream branch without conflicts in a secondary worktree. After
13
+ # validation (successful or not) of the last patch of a series, the worktree
14
+ # will be deleted.
15
+ #
16
+ # The following config variables can be set to change the default remote and
17
+ # remote ref that are used to apply the patches against:
18
+ #
19
+ # sendemail.validateRemote (default: origin)
20
+ # sendemail.validateRemoteRef (default: HEAD)
21
+ #
22
+ # Replace the TODO placeholders with appropriate checks according to your
23
+ # needs.
24
+
25
+ validate_cover_letter () {
26
+ file="$1"
27
+ # TODO: Replace with appropriate checks (e.g. spell checking).
28
+ true
29
+ }
30
+
31
+ validate_patch () {
32
+ file="$1"
33
+ # Ensure that the patch applies without conflicts.
34
+ git am -3 "$file" || return
35
+ # TODO: Replace with appropriate checks for this patch
36
+ # (e.g. checkpatch.pl).
37
+ true
38
+ }
39
+
40
+ validate_series () {
41
+ # TODO: Replace with appropriate checks for the whole series
42
+ # (e.g. quick build, coding style checks, etc.).
43
+ true
44
+ }
45
+
46
+ # main -------------------------------------------------------------------------
47
+
48
+ if test "$GIT_SENDEMAIL_FILE_COUNTER" = 1
49
+ then
50
+ remote=$(git config --default origin --get sendemail.validateRemote) &&
51
+ ref=$(git config --default HEAD --get sendemail.validateRemoteRef) &&
52
+ worktree=$(mktemp --tmpdir -d sendemail-validate.XXXXXXX) &&
53
+ git worktree add -fd --checkout "$worktree" "refs/remotes/$remote/$ref" &&
54
+ git config --replace-all sendemail.validateWorktree "$worktree"
55
+ else
56
+ worktree=$(git config --get sendemail.validateWorktree)
57
+ fi || {
58
+ echo "sendemail-validate: error: failed to prepare worktree" >&2
59
+ exit 1
60
+ }
61
+
62
+ unset GIT_DIR GIT_WORK_TREE
63
+ cd "$worktree" &&
64
+
65
+ if grep -q "^diff --git " "$1"
66
+ then
67
+ validate_patch "$1"
68
+ else
69
+ validate_cover_letter "$1"
70
+ fi &&
71
+
72
+ if test "$GIT_SENDEMAIL_FILE_COUNTER" = "$GIT_SENDEMAIL_FILE_TOTAL"
73
+ then
74
+ git config --unset-all sendemail.validateWorktree &&
75
+ trap 'git worktree remove -ff "$worktree"' EXIT &&
76
+ validate_series
77
+ fi
@@ -0,0 +1,128 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to block unannotated tags from entering.
4
+ # Called by "git receive-pack" with arguments: refname sha1-old sha1-new
5
+ #
6
+ # To enable this hook, rename this file to "update".
7
+ #
8
+ # Config
9
+ # ------
10
+ # hooks.allowunannotated
11
+ # This boolean sets whether unannotated tags will be allowed into the
12
+ # repository. By default they won't be.
13
+ # hooks.allowdeletetag
14
+ # This boolean sets whether deleting tags will be allowed in the
15
+ # repository. By default they won't be.
16
+ # hooks.allowmodifytag
17
+ # This boolean sets whether a tag may be modified after creation. By default
18
+ # it won't be.
19
+ # hooks.allowdeletebranch
20
+ # This boolean sets whether deleting branches will be allowed in the
21
+ # repository. By default they won't be.
22
+ # hooks.denycreatebranch
23
+ # This boolean sets whether remotely creating branches will be denied
24
+ # in the repository. By default this is allowed.
25
+ #
26
+
27
+ # --- Command line
28
+ refname="$1"
29
+ oldrev="$2"
30
+ newrev="$3"
31
+
32
+ # --- Safety check
33
+ if [ -z "$GIT_DIR" ]; then
34
+ echo "Don't run this script from the command line." >&2
35
+ echo " (if you want, you could supply GIT_DIR then run" >&2
36
+ echo " $0 <ref> <oldrev> <newrev>)" >&2
37
+ exit 1
38
+ fi
39
+
40
+ if [ -z "$refname" -o -z "$oldrev" -o -z "$newrev" ]; then
41
+ echo "usage: $0 <ref> <oldrev> <newrev>" >&2
42
+ exit 1
43
+ fi
44
+
45
+ # --- Config
46
+ allowunannotated=$(git config --type=bool hooks.allowunannotated)
47
+ allowdeletebranch=$(git config --type=bool hooks.allowdeletebranch)
48
+ denycreatebranch=$(git config --type=bool hooks.denycreatebranch)
49
+ allowdeletetag=$(git config --type=bool hooks.allowdeletetag)
50
+ allowmodifytag=$(git config --type=bool hooks.allowmodifytag)
51
+
52
+ # check for no description
53
+ projectdesc=$(sed -e '1q' "$GIT_DIR/description")
54
+ case "$projectdesc" in
55
+ "Unnamed repository"* | "")
56
+ echo "*** Project description file hasn't been set" >&2
57
+ exit 1
58
+ ;;
59
+ esac
60
+
61
+ # --- Check types
62
+ # if $newrev is 0000...0000, it's a commit to delete a ref.
63
+ zero=$(git hash-object --stdin </dev/null | tr '[0-9a-f]' '0')
64
+ if [ "$newrev" = "$zero" ]; then
65
+ newrev_type=delete
66
+ else
67
+ newrev_type=$(git cat-file -t $newrev)
68
+ fi
69
+
70
+ case "$refname","$newrev_type" in
71
+ refs/tags/*,commit)
72
+ # un-annotated tag
73
+ short_refname=${refname##refs/tags/}
74
+ if [ "$allowunannotated" != "true" ]; then
75
+ echo "*** The un-annotated tag, $short_refname, is not allowed in this repository" >&2
76
+ echo "*** Use 'git tag [ -a | -s ]' for tags you want to propagate." >&2
77
+ exit 1
78
+ fi
79
+ ;;
80
+ refs/tags/*,delete)
81
+ # delete tag
82
+ if [ "$allowdeletetag" != "true" ]; then
83
+ echo "*** Deleting a tag is not allowed in this repository" >&2
84
+ exit 1
85
+ fi
86
+ ;;
87
+ refs/tags/*,tag)
88
+ # annotated tag
89
+ if [ "$allowmodifytag" != "true" ] && git rev-parse $refname > /dev/null 2>&1
90
+ then
91
+ echo "*** Tag '$refname' already exists." >&2
92
+ echo "*** Modifying a tag is not allowed in this repository." >&2
93
+ exit 1
94
+ fi
95
+ ;;
96
+ refs/heads/*,commit)
97
+ # branch
98
+ if [ "$oldrev" = "$zero" -a "$denycreatebranch" = "true" ]; then
99
+ echo "*** Creating a branch is not allowed in this repository" >&2
100
+ exit 1
101
+ fi
102
+ ;;
103
+ refs/heads/*,delete)
104
+ # delete branch
105
+ if [ "$allowdeletebranch" != "true" ]; then
106
+ echo "*** Deleting a branch is not allowed in this repository" >&2
107
+ exit 1
108
+ fi
109
+ ;;
110
+ refs/remotes/*,commit)
111
+ # tracking branch
112
+ ;;
113
+ refs/remotes/*,delete)
114
+ # delete tracking branch
115
+ if [ "$allowdeletebranch" != "true" ]; then
116
+ echo "*** Deleting a tracking branch is not allowed in this repository" >&2
117
+ exit 1
118
+ fi
119
+ ;;
120
+ *)
121
+ # Anything else (is there anything else?)
122
+ echo "*** Update hook: unknown type of update to ref $refname of type $newrev_type" >&2
123
+ exit 1
124
+ ;;
125
+ esac
126
+
127
+ # --- Finished
128
+ exit 0
@@ -0,0 +1,6 @@
1
+ # git ls-files --others --exclude-from=.git/info/exclude
2
+ # Lines that start with '#' are comments.
3
+ # For a project mostly in C, the following would be a good set of
4
+ # exclude patterns (uncomment them if you want to use them):
5
+ # *.[oa]
6
+ # *~
@@ -0,0 +1 @@
1
+ 0000000000000000000000000000000000000000 e6f643917d5493f097fd04b2b79644b16d7890dc Alon Mayaffit <alon.mayafit@gmail.com> 1773749484 +0200 clone: from https://github.com/bmad-code-org/bmad-module-creative-intelligence-suite
@@ -0,0 +1 @@
1
+ 0000000000000000000000000000000000000000 e6f643917d5493f097fd04b2b79644b16d7890dc Alon Mayaffit <alon.mayafit@gmail.com> 1773749484 +0200 clone: from https://github.com/bmad-code-org/bmad-module-creative-intelligence-suite
@@ -0,0 +1 @@
1
+ 0000000000000000000000000000000000000000 e6f643917d5493f097fd04b2b79644b16d7890dc Alon Mayaffit <alon.mayafit@gmail.com> 1773749484 +0200 clone: from https://github.com/bmad-code-org/bmad-module-creative-intelligence-suite
@@ -0,0 +1,2 @@
1
+ # pack-refs with: peeled fully-peeled sorted
2
+ e6f643917d5493f097fd04b2b79644b16d7890dc refs/remotes/origin/main
@@ -0,0 +1 @@
1
+ e6f643917d5493f097fd04b2b79644b16d7890dc
@@ -0,0 +1 @@
1
+ ref: refs/remotes/origin/main
@@ -0,0 +1 @@
1
+ e6f643917d5493f097fd04b2b79644b16d7890dc
@@ -0,0 +1 @@
1
+ ref: refs/heads/main
@@ -0,0 +1,13 @@
1
+ [core]
2
+ repositoryformatversion = 0
3
+ filemode = false
4
+ bare = false
5
+ logallrefupdates = true
6
+ symlinks = false
7
+ ignorecase = true
8
+ [remote "origin"]
9
+ url = https://github.com/bmad-code-org/bmad-module-game-dev-studio.git
10
+ fetch = +refs/heads/main:refs/remotes/origin/main
11
+ [branch "main"]
12
+ remote = origin
13
+ merge = refs/heads/main
@@ -0,0 +1 @@
1
+ Unnamed repository; edit this file 'description' to name the repository.
@@ -0,0 +1,15 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to check the commit log message taken by
4
+ # applypatch from an e-mail message.
5
+ #
6
+ # The hook should exit with non-zero status after issuing an
7
+ # appropriate message if it wants to stop the commit. The hook is
8
+ # allowed to edit the commit message file.
9
+ #
10
+ # To enable this hook, rename this file to "applypatch-msg".
11
+
12
+ . git-sh-setup
13
+ commitmsg="$(git rev-parse --git-path hooks/commit-msg)"
14
+ test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"}
15
+ :
@@ -0,0 +1,24 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to check the commit log message.
4
+ # Called by "git commit" with one argument, the name of the file
5
+ # that has the commit message. The hook should exit with non-zero
6
+ # status after issuing an appropriate message if it wants to stop the
7
+ # commit. The hook is allowed to edit the commit message file.
8
+ #
9
+ # To enable this hook, rename this file to "commit-msg".
10
+
11
+ # Uncomment the below to add a Signed-off-by line to the message.
12
+ # Doing this in a hook is a bad idea in general, but the prepare-commit-msg
13
+ # hook is more suited to it.
14
+ #
15
+ # SOB=$(git var GIT_AUTHOR_IDENT | sed -n 's/^\(.*>\).*$/Signed-off-by: \1/p')
16
+ # grep -qs "^$SOB" "$1" || echo "$SOB" >> "$1"
17
+
18
+ # This example catches duplicate Signed-off-by lines.
19
+
20
+ test "" = "$(grep '^Signed-off-by: ' "$1" |
21
+ sort | uniq -c | sed -e '/^[ ]*1[ ]/d')" || {
22
+ echo >&2 Duplicate Signed-off-by lines.
23
+ exit 1
24
+ }
@@ -0,0 +1,174 @@
1
+ #!/usr/bin/perl
2
+
3
+ use strict;
4
+ use warnings;
5
+ use IPC::Open2;
6
+
7
+ # An example hook script to integrate Watchman
8
+ # (https://facebook.github.io/watchman/) with git to speed up detecting
9
+ # new and modified files.
10
+ #
11
+ # The hook is passed a version (currently 2) and last update token
12
+ # formatted as a string and outputs to stdout a new update token and
13
+ # all files that have been modified since the update token. Paths must
14
+ # be relative to the root of the working tree and separated by a single NUL.
15
+ #
16
+ # To enable this hook, rename this file to "query-watchman" and set
17
+ # 'git config core.fsmonitor .git/hooks/query-watchman'
18
+ #
19
+ my ($version, $last_update_token) = @ARGV;
20
+
21
+ # Uncomment for debugging
22
+ # print STDERR "$0 $version $last_update_token\n";
23
+
24
+ # Check the hook interface version
25
+ if ($version ne 2) {
26
+ die "Unsupported query-fsmonitor hook version '$version'.\n" .
27
+ "Falling back to scanning...\n";
28
+ }
29
+
30
+ my $git_work_tree = get_working_dir();
31
+
32
+ my $retry = 1;
33
+
34
+ my $json_pkg;
35
+ eval {
36
+ require JSON::XS;
37
+ $json_pkg = "JSON::XS";
38
+ 1;
39
+ } or do {
40
+ require JSON::PP;
41
+ $json_pkg = "JSON::PP";
42
+ };
43
+
44
+ launch_watchman();
45
+
46
+ sub launch_watchman {
47
+ my $o = watchman_query();
48
+ if (is_work_tree_watched($o)) {
49
+ output_result($o->{clock}, @{$o->{files}});
50
+ }
51
+ }
52
+
53
+ sub output_result {
54
+ my ($clockid, @files) = @_;
55
+
56
+ # Uncomment for debugging watchman output
57
+ # open (my $fh, ">", ".git/watchman-output.out");
58
+ # binmode $fh, ":utf8";
59
+ # print $fh "$clockid\n@files\n";
60
+ # close $fh;
61
+
62
+ binmode STDOUT, ":utf8";
63
+ print $clockid;
64
+ print "\0";
65
+ local $, = "\0";
66
+ print @files;
67
+ }
68
+
69
+ sub watchman_clock {
70
+ my $response = qx/watchman clock "$git_work_tree"/;
71
+ die "Failed to get clock id on '$git_work_tree'.\n" .
72
+ "Falling back to scanning...\n" if $? != 0;
73
+
74
+ return $json_pkg->new->utf8->decode($response);
75
+ }
76
+
77
+ sub watchman_query {
78
+ my $pid = open2(\*CHLD_OUT, \*CHLD_IN, 'watchman -j --no-pretty')
79
+ or die "open2() failed: $!\n" .
80
+ "Falling back to scanning...\n";
81
+
82
+ # In the query expression below we're asking for names of files that
83
+ # changed since $last_update_token but not from the .git folder.
84
+ #
85
+ # To accomplish this, we're using the "since" generator to use the
86
+ # recency index to select candidate nodes and "fields" to limit the
87
+ # output to file names only. Then we're using the "expression" term to
88
+ # further constrain the results.
89
+ my $last_update_line = "";
90
+ if (substr($last_update_token, 0, 1) eq "c") {
91
+ $last_update_token = "\"$last_update_token\"";
92
+ $last_update_line = qq[\n"since": $last_update_token,];
93
+ }
94
+ my $query = <<" END";
95
+ ["query", "$git_work_tree", {$last_update_line
96
+ "fields": ["name"],
97
+ "expression": ["not", ["dirname", ".git"]]
98
+ }]
99
+ END
100
+
101
+ # Uncomment for debugging the watchman query
102
+ # open (my $fh, ">", ".git/watchman-query.json");
103
+ # print $fh $query;
104
+ # close $fh;
105
+
106
+ print CHLD_IN $query;
107
+ close CHLD_IN;
108
+ my $response = do {local $/; <CHLD_OUT>};
109
+
110
+ # Uncomment for debugging the watch response
111
+ # open ($fh, ">", ".git/watchman-response.json");
112
+ # print $fh $response;
113
+ # close $fh;
114
+
115
+ die "Watchman: command returned no output.\n" .
116
+ "Falling back to scanning...\n" if $response eq "";
117
+ die "Watchman: command returned invalid output: $response\n" .
118
+ "Falling back to scanning...\n" unless $response =~ /^\{/;
119
+
120
+ return $json_pkg->new->utf8->decode($response);
121
+ }
122
+
123
+ sub is_work_tree_watched {
124
+ my ($output) = @_;
125
+ my $error = $output->{error};
126
+ if ($retry > 0 and $error and $error =~ m/unable to resolve root .* directory (.*) is not watched/) {
127
+ $retry--;
128
+ my $response = qx/watchman watch "$git_work_tree"/;
129
+ die "Failed to make watchman watch '$git_work_tree'.\n" .
130
+ "Falling back to scanning...\n" if $? != 0;
131
+ $output = $json_pkg->new->utf8->decode($response);
132
+ $error = $output->{error};
133
+ die "Watchman: $error.\n" .
134
+ "Falling back to scanning...\n" if $error;
135
+
136
+ # Uncomment for debugging watchman output
137
+ # open (my $fh, ">", ".git/watchman-output.out");
138
+ # close $fh;
139
+
140
+ # Watchman will always return all files on the first query so
141
+ # return the fast "everything is dirty" flag to git and do the
142
+ # Watchman query just to get it over with now so we won't pay
143
+ # the cost in git to look up each individual file.
144
+ my $o = watchman_clock();
145
+ $error = $output->{error};
146
+
147
+ die "Watchman: $error.\n" .
148
+ "Falling back to scanning...\n" if $error;
149
+
150
+ output_result($o->{clock}, ("/"));
151
+ $last_update_token = $o->{clock};
152
+
153
+ eval { launch_watchman() };
154
+ return 0;
155
+ }
156
+
157
+ die "Watchman: $error.\n" .
158
+ "Falling back to scanning...\n" if $error;
159
+
160
+ return 1;
161
+ }
162
+
163
+ sub get_working_dir {
164
+ my $working_dir;
165
+ if ($^O =~ 'msys' || $^O =~ 'cygwin') {
166
+ $working_dir = Win32::GetCwd();
167
+ $working_dir =~ tr/\\/\//;
168
+ } else {
169
+ require Cwd;
170
+ $working_dir = Cwd::cwd();
171
+ }
172
+
173
+ return $working_dir;
174
+ }
@@ -0,0 +1,8 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to prepare a packed repository for use over
4
+ # dumb transports.
5
+ #
6
+ # To enable this hook, rename this file to "post-update".
7
+
8
+ exec git update-server-info
@@ -0,0 +1,14 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to verify what is about to be committed
4
+ # by applypatch from an e-mail message.
5
+ #
6
+ # The hook should exit with non-zero status after issuing an
7
+ # appropriate message if it wants to stop the commit.
8
+ #
9
+ # To enable this hook, rename this file to "pre-applypatch".
10
+
11
+ . git-sh-setup
12
+ precommit="$(git rev-parse --git-path hooks/pre-commit)"
13
+ test -x "$precommit" && exec "$precommit" ${1+"$@"}
14
+ :
@@ -0,0 +1,49 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to verify what is about to be committed.
4
+ # Called by "git commit" with no arguments. The hook should
5
+ # exit with non-zero status after issuing an appropriate message if
6
+ # it wants to stop the commit.
7
+ #
8
+ # To enable this hook, rename this file to "pre-commit".
9
+
10
+ if git rev-parse --verify HEAD >/dev/null 2>&1
11
+ then
12
+ against=HEAD
13
+ else
14
+ # Initial commit: diff against an empty tree object
15
+ against=$(git hash-object -t tree /dev/null)
16
+ fi
17
+
18
+ # If you want to allow non-ASCII filenames set this variable to true.
19
+ allownonascii=$(git config --type=bool hooks.allownonascii)
20
+
21
+ # Redirect output to stderr.
22
+ exec 1>&2
23
+
24
+ # Cross platform projects tend to avoid non-ASCII filenames; prevent
25
+ # them from being added to the repository. We exploit the fact that the
26
+ # printable range starts at the space character and ends with tilde.
27
+ if [ "$allownonascii" != "true" ] &&
28
+ # Note that the use of brackets around a tr range is ok here, (it's
29
+ # even required, for portability to Solaris 10's /usr/bin/tr), since
30
+ # the square bracket bytes happen to fall in the designated range.
31
+ test $(git diff-index --cached --name-only --diff-filter=A -z $against |
32
+ LC_ALL=C tr -d '[ -~]\0' | wc -c) != 0
33
+ then
34
+ cat <<\EOF
35
+ Error: Attempt to add a non-ASCII file name.
36
+
37
+ This can cause problems if you want to work with people on other platforms.
38
+
39
+ To be portable it is advisable to rename the file.
40
+
41
+ If you know what you are doing you can disable this check using:
42
+
43
+ git config hooks.allownonascii true
44
+ EOF
45
+ exit 1
46
+ fi
47
+
48
+ # If there are whitespace errors, print the offending file names and fail.
49
+ exec git diff-index --check --cached $against --
@@ -0,0 +1,13 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to verify what is about to be committed.
4
+ # Called by "git merge" with no arguments. The hook should
5
+ # exit with non-zero status after issuing an appropriate message to
6
+ # stderr if it wants to stop the merge commit.
7
+ #
8
+ # To enable this hook, rename this file to "pre-merge-commit".
9
+
10
+ . git-sh-setup
11
+ test -x "$GIT_DIR/hooks/pre-commit" &&
12
+ exec "$GIT_DIR/hooks/pre-commit"
13
+ :
@@ -0,0 +1,53 @@
1
+ #!/bin/sh
2
+
3
+ # An example hook script to verify what is about to be pushed. Called by "git
4
+ # push" after it has checked the remote status, but before anything has been
5
+ # pushed. If this script exits with a non-zero status nothing will be pushed.
6
+ #
7
+ # This hook is called with the following parameters:
8
+ #
9
+ # $1 -- Name of the remote to which the push is being done
10
+ # $2 -- URL to which the push is being done
11
+ #
12
+ # If pushing without using a named remote those arguments will be equal.
13
+ #
14
+ # Information about the commits which are being pushed is supplied as lines to
15
+ # the standard input in the form:
16
+ #
17
+ # <local ref> <local oid> <remote ref> <remote oid>
18
+ #
19
+ # This sample shows how to prevent push of commits where the log message starts
20
+ # with "WIP" (work in progress).
21
+
22
+ remote="$1"
23
+ url="$2"
24
+
25
+ zero=$(git hash-object --stdin </dev/null | tr '[0-9a-f]' '0')
26
+
27
+ while read local_ref local_oid remote_ref remote_oid
28
+ do
29
+ if test "$local_oid" = "$zero"
30
+ then
31
+ # Handle delete
32
+ :
33
+ else
34
+ if test "$remote_oid" = "$zero"
35
+ then
36
+ # New branch, examine all commits
37
+ range="$local_oid"
38
+ else
39
+ # Update to existing branch, examine new commits
40
+ range="$remote_oid..$local_oid"
41
+ fi
42
+
43
+ # Check for WIP commit
44
+ commit=$(git rev-list -n 1 --grep '^WIP' "$range")
45
+ if test -n "$commit"
46
+ then
47
+ echo >&2 "Found WIP commit in $local_ref, not pushing"
48
+ exit 1
49
+ fi
50
+ fi
51
+ done
52
+
53
+ exit 0