yadflow 4.9.0 → 4.10.0
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.
- package/CHANGELOG.md +87 -0
- package/README.md +4 -3
- package/bin/commands.mjs +6 -0
- package/bin/yad.mjs +101 -6
- package/cli/agent-guard.mjs +793 -65
- package/cli/agent-rules.mjs +33 -5
- package/cli/argv-flags.mjs +1 -1
- package/cli/ci-check.mjs +45 -1
- package/cli/codeowners-command.mjs +72 -6
- package/cli/commit.mjs +17 -3
- package/cli/docs.mjs +2 -0
- package/cli/doctor.mjs +71 -12
- package/cli/epic-state.mjs +94 -4
- package/cli/epic.mjs +11 -7
- package/cli/fold.mjs +31 -6
- package/cli/guide.mjs +3 -1
- package/cli/hook.mjs +50 -7
- package/cli/issue-links.mjs +61 -0
- package/cli/issues-act.mjs +327 -0
- package/cli/issues-write.mjs +428 -0
- package/cli/issues.mjs +474 -0
- package/cli/lifecycle.mjs +7 -0
- package/cli/manifest.mjs +9 -3
- package/cli/openpr.mjs +24 -4
- package/cli/plan.mjs +2 -0
- package/cli/platform.mjs +157 -2
- package/cli/protection.mjs +21 -3
- package/cli/reconcile.mjs +1 -1
- package/cli/run-checks.mjs +10 -2
- package/cli/scan.mjs +314 -0
- package/cli/setup.mjs +12 -3
- package/cli/standup.mjs +33 -7
- package/cli/story-frames.mjs +17 -6
- package/cli/test-agents-file.mjs +378 -11
- package/cli/test-build.mjs +25 -0
- package/cli/test-ci-check.mjs +469 -10
- package/cli/test-guide.mjs +7 -0
- package/cli/test-node.mjs +15 -0
- package/cli/test-run-checks.mjs +17 -0
- package/cli/test-setup-agent.mjs +14 -0
- package/cli/test-story-frames.mjs +74 -4
- package/cli/toolbox-connect.mjs +244 -0
- package/cli/toolbox.mjs +129 -9
- package/package.json +7 -3
- package/skills/sdlc/config.yaml +1 -1
- package/skills/sdlc/module-help.csv +3 -1
- package/skills/yad-analysis/SKILL.md +4 -0
- package/skills/yad-backfill/SKILL.md +4 -0
- package/skills/yad-change/SKILL.md +4 -0
- package/skills/yad-checks/SKILL.md +13 -7
- package/skills/yad-checks/references/check-gates.md +62 -30
- package/skills/yad-checks/templates/checks/member-check.mjs +3 -2
- package/skills/yad-checks/templates/checks/risk-map-check.sh +2 -2
- package/skills/yad-checks/templates/checks/verified-commits.sh +3 -3
- package/skills/yad-checks/templates/github/yad-checks.yml +357 -69
- package/skills/yad-checks/templates/github/yad-pr-text.yml +118 -0
- package/skills/yad-checks/templates/github/yad-product-checks.yml +130 -54
- package/skills/yad-checks/templates/github/yad-product-pr-text.yml +131 -0
- package/skills/yad-checks/templates/github/yad-update-guard.yml +2 -1
- package/skills/yad-checks/templates/github/yad-verified-commits.yml +49 -3
- package/skills/yad-checks/templates/gitlab/yad-checks.gitlab-ci.yml +79 -20
- package/skills/yad-checks/templates/gitlab/yad-product-checks.gitlab-ci.yml +59 -9
- package/skills/yad-checks/templates/gitlab/yad-update-guard.gitlab-ci.yml +1 -0
- package/skills/yad-checks/templates/gitlab/yad-verified-commits.gitlab-ci.yml +49 -1
- package/skills/yad-checks/templates/hooks/agent-guard.mjs +44 -10
- package/skills/yad-checks/templates/hooks/ledger-guard-cursor.mjs +12 -6
- package/skills/yad-commit/SKILL.md +3 -1
- package/skills/yad-connect-design/SKILL.md +42 -10
- package/skills/yad-connect-design/references/design-context.md +35 -5
- package/skills/yad-connect-design/references/design-registry.md +3 -3
- package/skills/yad-connect-learning/SKILL.md +12 -2
- package/skills/yad-connect-repos/SKILL.md +4 -0
- package/skills/yad-connect-testing/SKILL.md +22 -5
- package/skills/yad-connect-testing/references/testing-context.md +1 -1
- package/skills/yad-epic/SKILL.md +4 -0
- package/skills/yad-epic/references/state-schema.md +15 -0
- package/skills/yad-guide/SKILL.md +8 -4
- package/skills/yad-implement/SKILL.md +56 -4
- package/skills/yad-implement/references/implement-conventions.md +2 -1
- package/skills/yad-issues/SKILL.md +53 -0
- package/skills/yad-learn/SKILL.md +4 -0
- package/skills/yad-open-pr/SKILL.md +6 -0
- package/skills/yad-pr-template/SKILL.md +2 -1
- package/skills/yad-pr-template/templates/checks/pr-title.sh +34 -2
- package/skills/yad-product-bridge/references/bridge.md +28 -0
- package/skills/yad-product-bridge/templates/github/yad-gate-sync.yml +25 -11
- package/skills/yad-product-bridge/templates/gitlab/yad-gate-sync.gitlab-ci.yml +38 -14
- package/skills/yad-run/SKILL.md +5 -0
- package/skills/yad-scan/SKILL.md +51 -0
- package/skills/yad-spec/SKILL.md +13 -2
- package/skills/yad-test-cases/SKILL.md +18 -2
- package/skills/yad-ui/SKILL.md +43 -8
- package/skills/yad-checks/templates/gitlab/.gitlab-ci.yml +0 -49
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# yad-managed: yad-checks
|
|
2
|
+
# SDLC pattern gates on the PR text (profile: code): the PR title and the PR body follow the convention.
|
|
3
|
+
# Its own workflow (#425) so that an edit of the title or body re-runs these two checks and nothing else.
|
|
4
|
+
# A gate job skipped by `if:` counts as passed, so a run of yad-checks started by an edit would turn a
|
|
5
|
+
# failed gate green. This file is OWNED by yad-checks (the marker on line 1 identifies it).
|
|
6
|
+
#
|
|
7
|
+
# Gate scripts (#426): every job runs the BASE branch's copy of checks/, never the PR's own, so a PR that
|
|
8
|
+
# changes a gate script is still judged by the script already merged. A script the base does not have yet
|
|
9
|
+
# (the PR that first installs the gates, or a `yad update` that adds one) runs from the PR, with a note.
|
|
10
|
+
# The base's script runs with THIS file's call: keep every call one the previous release's script accepts.
|
|
11
|
+
# This file itself still comes from the PR: protect checks/ and the CI files with a CODEOWNERS rule and
|
|
12
|
+
# a required Code Owner review (docs/branch-protection.md, "Who may change the gates").
|
|
13
|
+
name: yad-pr-text
|
|
14
|
+
on:
|
|
15
|
+
pull_request:
|
|
16
|
+
# `edited` (beyond the opened/synchronize/reopened defaults) so a PR title/body correction
|
|
17
|
+
# re-runs these checks without a close/reopen — e.g. fixing a body the pr-template gate held.
|
|
18
|
+
types: [opened, synchronize, reopened, edited]
|
|
19
|
+
branches: ["**"]
|
|
20
|
+
|
|
21
|
+
# A newer edit of the PR text cancels this workflow's older run on the same commit (#428): both checks read the
|
|
22
|
+
# PR's current title and body, so the newest run is the one that counts. The group names the commit too, so a
|
|
23
|
+
# late-delivered edit of an older commit can never cancel the run a newer push started.
|
|
24
|
+
concurrency:
|
|
25
|
+
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}-${{ github.event.pull_request.head.sha }}
|
|
26
|
+
cancel-in-progress: true
|
|
27
|
+
|
|
28
|
+
# Read-only: no check here writes to the repo.
|
|
29
|
+
permissions:
|
|
30
|
+
contents: read
|
|
31
|
+
|
|
32
|
+
jobs:
|
|
33
|
+
# Pass the title via env (never interpolate untrusted ${{ }} into a run line — injection-safe).
|
|
34
|
+
pr-title:
|
|
35
|
+
runs-on: ubuntu-latest
|
|
36
|
+
timeout-minutes: 10
|
|
37
|
+
env:
|
|
38
|
+
PR_TITLE: ${{ github.event.pull_request.title }}
|
|
39
|
+
steps:
|
|
40
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
41
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
42
|
+
- name: Gate scripts from the base branch (#426)
|
|
43
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
44
|
+
run: |
|
|
45
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
46
|
+
(
|
|
47
|
+
set -euo pipefail
|
|
48
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
49
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
50
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
51
|
+
t="$(git ls-tree "$b" checks)"
|
|
52
|
+
case "$t" in
|
|
53
|
+
"") on_base=0 ;;
|
|
54
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
55
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
56
|
+
esac
|
|
57
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
58
|
+
n=0
|
|
59
|
+
while IFS= read -r -d '' e; do
|
|
60
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
61
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
62
|
+
case "$m" in
|
|
63
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
64
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
65
|
+
esac
|
|
66
|
+
n=$((n + 1))
|
|
67
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
68
|
+
done < "$d/.pr"
|
|
69
|
+
rm -f "$d/.pr"
|
|
70
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
71
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
72
|
+
)
|
|
73
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
74
|
+
- run: bash "$YAD_CHECKS/pr-title.sh" --profile code "$PR_TITLE"
|
|
75
|
+
|
|
76
|
+
pr-template:
|
|
77
|
+
runs-on: ubuntu-latest
|
|
78
|
+
timeout-minutes: 10
|
|
79
|
+
env:
|
|
80
|
+
PR_BODY: ${{ github.event.pull_request.body }}
|
|
81
|
+
steps:
|
|
82
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
83
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
84
|
+
- name: Gate scripts from the base branch (#426)
|
|
85
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
86
|
+
run: |
|
|
87
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
88
|
+
(
|
|
89
|
+
set -euo pipefail
|
|
90
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
91
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
92
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
93
|
+
t="$(git ls-tree "$b" checks)"
|
|
94
|
+
case "$t" in
|
|
95
|
+
"") on_base=0 ;;
|
|
96
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
97
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
98
|
+
esac
|
|
99
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
100
|
+
n=0
|
|
101
|
+
while IFS= read -r -d '' e; do
|
|
102
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
103
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
104
|
+
case "$m" in
|
|
105
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
106
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
107
|
+
esac
|
|
108
|
+
n=$((n + 1))
|
|
109
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
110
|
+
done < "$d/.pr"
|
|
111
|
+
rm -f "$d/.pr"
|
|
112
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
113
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
114
|
+
)
|
|
115
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
116
|
+
- run: |
|
|
117
|
+
body="$(mktemp)"; printf '%s' "$PR_BODY" > "$body"
|
|
118
|
+
bash "$YAD_CHECKS/pr-template.sh" --profile code "$body"
|
|
@@ -1,86 +1,162 @@
|
|
|
1
1
|
# yad-managed: yad-checks
|
|
2
|
-
#
|
|
3
|
-
#
|
|
4
|
-
#
|
|
5
|
-
#
|
|
6
|
-
#
|
|
7
|
-
#
|
|
8
|
-
#
|
|
2
|
+
# Gates for the PRODUCT's PRs: commit subjects (Conventional Commits, `--profile product`), the CI-owned
|
|
3
|
+
# gate ledger, and member files. The PR title and body are checked by yad-product-pr-text.yml (#425).
|
|
4
|
+
# Standalone workflow so it never collides with the code-repo yad-checks workflow.
|
|
5
|
+
#
|
|
6
|
+
# Gate scripts (#426): every job runs the BASE branch's copy of checks/, never the PR's own, so a PR that
|
|
7
|
+
# changes a gate script is still judged by the script already merged. A script the base does not have yet
|
|
8
|
+
# (the PR that first installs the gates, or a `yad update` that adds one) runs from the PR, with a note.
|
|
9
|
+
# The base's script runs with THIS file's call: keep every call one the previous release's script accepts.
|
|
10
|
+
# This file itself still comes from the PR: protect checks/ and the CI files with a CODEOWNERS rule and
|
|
11
|
+
# a required Code Owner review (docs/branch-protection.md, "Who may change the gates").
|
|
9
12
|
name: yad-product-checks
|
|
10
13
|
on:
|
|
11
14
|
pull_request:
|
|
12
|
-
# `edited` (
|
|
13
|
-
#
|
|
14
|
-
|
|
15
|
+
# Never `edited` (#425). A job skipped by `if:` counts as passed, so a run started by an edit of the PR
|
|
16
|
+
# text would show every gate here as passed on the same commit — a failed gate could turn green. The two
|
|
17
|
+
# checks that read the PR text, pr-title and pr-template, run from yad-product-pr-text.yml, which does
|
|
18
|
+
# start on an edit.
|
|
19
|
+
types: [opened, synchronize, reopened]
|
|
15
20
|
branches: ["**"]
|
|
16
21
|
|
|
22
|
+
# A newer push to the same pull request cancels this workflow's older run (#428): only the newest commit
|
|
23
|
+
# can be merged, and every gate here re-reads the whole PR range, so the older run checks nothing it misses.
|
|
24
|
+
concurrency:
|
|
25
|
+
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
|
|
26
|
+
cancel-in-progress: true
|
|
27
|
+
|
|
17
28
|
# Read-only by default: no gate here writes to the repo. A job that needs more asks for it itself.
|
|
18
29
|
permissions:
|
|
19
30
|
contents: read
|
|
20
31
|
|
|
21
32
|
jobs:
|
|
22
|
-
# commit-message
|
|
23
|
-
# `edited` event (only pr-title/pr-template need to re-check a title/body fix).
|
|
33
|
+
# commit-message reads the commit range. The PR title and body are checked by yad-product-pr-text.yml.
|
|
24
34
|
commit-message:
|
|
25
35
|
runs-on: ubuntu-latest
|
|
26
|
-
|
|
27
|
-
steps:
|
|
28
|
-
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
|
|
29
|
-
with: { fetch-depth: 0 }
|
|
30
|
-
- run: bash checks/commit-message.sh --profile product "origin/${{ github.base_ref }}"
|
|
31
|
-
|
|
32
|
-
# Pass the title via env (never interpolate untrusted ${{ }} into a run line — injection-safe).
|
|
33
|
-
# fetch-depth: 0 + the base ref give us the PR's changed paths, so the gate can reject an artifact
|
|
34
|
-
# change (epics/**) riding a non-review head past the Shape review with a plain code title.
|
|
35
|
-
pr-title:
|
|
36
|
-
runs-on: ubuntu-latest
|
|
37
|
-
env:
|
|
38
|
-
PR_TITLE: ${{ github.event.pull_request.title }}
|
|
39
|
-
PR_HEAD: ${{ github.event.pull_request.head.ref }}
|
|
40
|
-
BASE_REF: ${{ github.base_ref }}
|
|
41
|
-
steps:
|
|
42
|
-
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
|
|
43
|
-
with: { fetch-depth: 0 }
|
|
44
|
-
- run: |
|
|
45
|
-
changed="$(mktemp)"; git -c core.quotePath=false diff --no-renames --name-only "origin/${BASE_REF}...HEAD" > "$changed"
|
|
46
|
-
bash checks/pr-title.sh --profile product --head "$PR_HEAD" --changed "$changed" "$PR_TITLE"
|
|
47
|
-
|
|
48
|
-
pr-template:
|
|
49
|
-
runs-on: ubuntu-latest
|
|
50
|
-
env:
|
|
51
|
-
PR_BODY: ${{ github.event.pull_request.body }}
|
|
52
|
-
PR_HEAD: ${{ github.event.pull_request.head.ref }}
|
|
53
|
-
BASE_REF: ${{ github.base_ref }}
|
|
36
|
+
timeout-minutes: 10
|
|
54
37
|
steps:
|
|
55
|
-
- uses: actions/checkout@
|
|
56
|
-
with: { fetch-depth: 0 }
|
|
57
|
-
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
38
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
39
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
40
|
+
- name: Gate scripts from the base branch (#426)
|
|
41
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
42
|
+
run: |
|
|
43
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
44
|
+
(
|
|
45
|
+
set -euo pipefail
|
|
46
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
47
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
48
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
49
|
+
t="$(git ls-tree "$b" checks)"
|
|
50
|
+
case "$t" in
|
|
51
|
+
"") on_base=0 ;;
|
|
52
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
53
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
54
|
+
esac
|
|
55
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
56
|
+
n=0
|
|
57
|
+
while IFS= read -r -d '' e; do
|
|
58
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
59
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
60
|
+
case "$m" in
|
|
61
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
62
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
63
|
+
esac
|
|
64
|
+
n=$((n + 1))
|
|
65
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
66
|
+
done < "$d/.pr"
|
|
67
|
+
rm -f "$d/.pr"
|
|
68
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
69
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
70
|
+
)
|
|
71
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
72
|
+
- run: bash "$YAD_CHECKS/commit-message.sh" --profile product "origin/${{ github.base_ref }}"
|
|
61
73
|
|
|
62
74
|
# The gate ledger is CI-owned: reject non-bot commits to .sdlc/{state,approvals,comments,product-prs,hub-prs}.json
|
|
63
75
|
# or reviews/*.md (.sdlc/contract-lock.json is artifact-side and allowed). The one other exception is a
|
|
64
76
|
# brand-new epic's seed, which no CI path can write, so it rides this first review PR (#162).
|
|
65
77
|
ledger-guard:
|
|
66
78
|
runs-on: ubuntu-latest
|
|
67
|
-
|
|
79
|
+
timeout-minutes: 10
|
|
68
80
|
steps:
|
|
69
|
-
- uses: actions/checkout@
|
|
70
|
-
with: { fetch-depth: 0 }
|
|
71
|
-
-
|
|
81
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
82
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
83
|
+
- name: Gate scripts from the base branch (#426)
|
|
84
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
85
|
+
run: |
|
|
86
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
87
|
+
(
|
|
88
|
+
set -euo pipefail
|
|
89
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
90
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
91
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
92
|
+
t="$(git ls-tree "$b" checks)"
|
|
93
|
+
case "$t" in
|
|
94
|
+
"") on_base=0 ;;
|
|
95
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
96
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
97
|
+
esac
|
|
98
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
99
|
+
n=0
|
|
100
|
+
while IFS= read -r -d '' e; do
|
|
101
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
102
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
103
|
+
case "$m" in
|
|
104
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
105
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
106
|
+
esac
|
|
107
|
+
n=$((n + 1))
|
|
108
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
109
|
+
done < "$d/.pr"
|
|
110
|
+
rm -f "$d/.pr"
|
|
111
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
112
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
113
|
+
)
|
|
114
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
115
|
+
- run: bash "$YAD_CHECKS/ledger-guard.sh" "origin/${{ github.base_ref }}"
|
|
72
116
|
|
|
73
117
|
# E131: a member file (.sdlc/members/) is changed only by its own person, and every email it adds must be
|
|
74
118
|
# the author of a commit in this PR that GitHub attributes to that person. Needs a read token to ask
|
|
75
119
|
# GitHub who a commit belongs to; the PR author comes from the event, never from the PR's own files.
|
|
76
120
|
member-check:
|
|
77
121
|
runs-on: ubuntu-latest
|
|
78
|
-
|
|
122
|
+
timeout-minutes: 10
|
|
79
123
|
env:
|
|
80
124
|
PR_AUTHOR: ${{ github.event.pull_request.user.login }}
|
|
81
125
|
PR_AUTHOR_ID: ${{ github.event.pull_request.user.id }}
|
|
82
126
|
GH_TOKEN: ${{ github.token }}
|
|
83
127
|
steps:
|
|
84
|
-
- uses: actions/checkout@
|
|
85
|
-
with: { fetch-depth: 0 }
|
|
86
|
-
-
|
|
128
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
129
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
130
|
+
- name: Gate scripts from the base branch (#426)
|
|
131
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
132
|
+
run: |
|
|
133
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
134
|
+
(
|
|
135
|
+
set -euo pipefail
|
|
136
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
137
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
138
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
139
|
+
t="$(git ls-tree "$b" checks)"
|
|
140
|
+
case "$t" in
|
|
141
|
+
"") on_base=0 ;;
|
|
142
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
143
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
144
|
+
esac
|
|
145
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
146
|
+
n=0
|
|
147
|
+
while IFS= read -r -d '' e; do
|
|
148
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
149
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
150
|
+
case "$m" in
|
|
151
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
152
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
153
|
+
esac
|
|
154
|
+
n=$((n + 1))
|
|
155
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
156
|
+
done < "$d/.pr"
|
|
157
|
+
rm -f "$d/.pr"
|
|
158
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
159
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
160
|
+
)
|
|
161
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
162
|
+
- run: node "$YAD_CHECKS/member-check.mjs" "origin/${{ github.base_ref }}"
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
# yad-managed: yad-checks
|
|
2
|
+
# Pattern gates on the PRODUCT's PR text, with `--profile product`, split by head branch:
|
|
3
|
+
# review/EP-* PRs are Shape artifact-review vehicles — a `review: <artifact> (EP-<slug>)` title
|
|
4
|
+
# and the Product artifact-review template body.
|
|
5
|
+
# every other PR is a tooling/code change to the Product itself — a Conventional-Commits title and the
|
|
6
|
+
# code task template body (same convention the code repos use).
|
|
7
|
+
# Its own workflow (#425) so that an edit of the title or body re-runs these two checks and nothing else.
|
|
8
|
+
# A gate job skipped by `if:` counts as passed, so a run of yad-product-checks started by an edit would
|
|
9
|
+
# turn a failed gate green.
|
|
10
|
+
#
|
|
11
|
+
# Gate scripts (#426): every job runs the BASE branch's copy of checks/, never the PR's own, so a PR that
|
|
12
|
+
# changes a gate script is still judged by the script already merged. A script the base does not have yet
|
|
13
|
+
# (the PR that first installs the gates, or a `yad update` that adds one) runs from the PR, with a note.
|
|
14
|
+
# The base's script runs with THIS file's call: keep every call one the previous release's script accepts.
|
|
15
|
+
# This file itself still comes from the PR: protect checks/ and the CI files with a CODEOWNERS rule and
|
|
16
|
+
# a required Code Owner review (docs/branch-protection.md, "Who may change the gates").
|
|
17
|
+
name: yad-product-pr-text
|
|
18
|
+
on:
|
|
19
|
+
pull_request:
|
|
20
|
+
# `edited` (beyond the opened/synchronize/reopened defaults) so a PR title/body correction
|
|
21
|
+
# re-runs these checks without a close/reopen — e.g. fixing a body the pr-template gate held.
|
|
22
|
+
types: [opened, synchronize, reopened, edited]
|
|
23
|
+
branches: ["**"]
|
|
24
|
+
|
|
25
|
+
# A newer edit of the PR text cancels this workflow's older run on the same commit (#428): both checks read the
|
|
26
|
+
# PR's current title and body, so the newest run is the one that counts. The group names the commit too, so a
|
|
27
|
+
# late-delivered edit of an older commit can never cancel the run a newer push started.
|
|
28
|
+
concurrency:
|
|
29
|
+
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}-${{ github.event.pull_request.head.sha }}
|
|
30
|
+
cancel-in-progress: true
|
|
31
|
+
|
|
32
|
+
# Read-only: no check here writes to the repo.
|
|
33
|
+
permissions:
|
|
34
|
+
contents: read
|
|
35
|
+
|
|
36
|
+
jobs:
|
|
37
|
+
# Pass the title via env (never interpolate untrusted ${{ }} into a run line — injection-safe).
|
|
38
|
+
# fetch-depth: 0 + the base ref give us the PR's changed paths, so the gate can reject an artifact
|
|
39
|
+
# change (epics/**) riding a non-review head past the Shape review with a plain code title.
|
|
40
|
+
pr-title:
|
|
41
|
+
runs-on: ubuntu-latest
|
|
42
|
+
timeout-minutes: 10
|
|
43
|
+
env:
|
|
44
|
+
PR_TITLE: ${{ github.event.pull_request.title }}
|
|
45
|
+
PR_HEAD: ${{ github.event.pull_request.head.ref }}
|
|
46
|
+
BASE_REF: ${{ github.base_ref }}
|
|
47
|
+
steps:
|
|
48
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
49
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
50
|
+
- name: Gate scripts from the base branch (#426)
|
|
51
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
52
|
+
run: |
|
|
53
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
54
|
+
(
|
|
55
|
+
set -euo pipefail
|
|
56
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
57
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
58
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
59
|
+
t="$(git ls-tree "$b" checks)"
|
|
60
|
+
case "$t" in
|
|
61
|
+
"") on_base=0 ;;
|
|
62
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
63
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
64
|
+
esac
|
|
65
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
66
|
+
n=0
|
|
67
|
+
while IFS= read -r -d '' e; do
|
|
68
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
69
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
70
|
+
case "$m" in
|
|
71
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
72
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
73
|
+
esac
|
|
74
|
+
n=$((n + 1))
|
|
75
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
76
|
+
done < "$d/.pr"
|
|
77
|
+
rm -f "$d/.pr"
|
|
78
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
79
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
80
|
+
)
|
|
81
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
82
|
+
- run: |
|
|
83
|
+
changed="$(mktemp)"; git -c core.quotePath=false diff --no-renames --name-only "origin/${BASE_REF}...HEAD" > "$changed"
|
|
84
|
+
bash "$YAD_CHECKS/pr-title.sh" --profile product --head "$PR_HEAD" --changed "$changed" "$PR_TITLE"
|
|
85
|
+
|
|
86
|
+
pr-template:
|
|
87
|
+
runs-on: ubuntu-latest
|
|
88
|
+
timeout-minutes: 10
|
|
89
|
+
env:
|
|
90
|
+
PR_BODY: ${{ github.event.pull_request.body }}
|
|
91
|
+
PR_HEAD: ${{ github.event.pull_request.head.ref }}
|
|
92
|
+
BASE_REF: ${{ github.base_ref }}
|
|
93
|
+
steps:
|
|
94
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
95
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
96
|
+
- name: Gate scripts from the base branch (#426)
|
|
97
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
98
|
+
run: |
|
|
99
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
100
|
+
(
|
|
101
|
+
set -euo pipefail
|
|
102
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
103
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
104
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
105
|
+
t="$(git ls-tree "$b" checks)"
|
|
106
|
+
case "$t" in
|
|
107
|
+
"") on_base=0 ;;
|
|
108
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
109
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
110
|
+
esac
|
|
111
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
112
|
+
n=0
|
|
113
|
+
while IFS= read -r -d '' e; do
|
|
114
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
115
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
116
|
+
case "$m" in
|
|
117
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
118
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
119
|
+
esac
|
|
120
|
+
n=$((n + 1))
|
|
121
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
122
|
+
done < "$d/.pr"
|
|
123
|
+
rm -f "$d/.pr"
|
|
124
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
125
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
126
|
+
)
|
|
127
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
128
|
+
- run: |
|
|
129
|
+
changed="$(mktemp)"; git -c core.quotePath=false diff --no-renames --name-only "origin/${BASE_REF}...HEAD" > "$changed"
|
|
130
|
+
body="$(mktemp)"; printf '%s' "$PR_BODY" > "$body"
|
|
131
|
+
bash "$YAD_CHECKS/pr-template.sh" --profile product --head "$PR_HEAD" --changed "$changed" "$body"
|
|
@@ -27,10 +27,11 @@ jobs:
|
|
|
27
27
|
# Only the default branch — pushes to feature branches are reviewed via their PR gate suite.
|
|
28
28
|
if: github.ref_name == github.event.repository.default_branch
|
|
29
29
|
runs-on: ubuntu-latest
|
|
30
|
+
timeout-minutes: 10
|
|
30
31
|
env:
|
|
31
32
|
GH_TOKEN: ${{ github.token }} # read-only: gh api commits/<sha> for the Verified badge
|
|
32
33
|
steps:
|
|
33
|
-
- uses: actions/checkout@
|
|
34
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
34
35
|
with: { fetch-depth: 0 }
|
|
35
36
|
- name: Resolve the pushed range base
|
|
36
37
|
id: base
|
|
@@ -3,20 +3,66 @@
|
|
|
3
3
|
# must contain only commits whose signature the platform marks Verified. Who may author them is who has
|
|
4
4
|
# write access to the repo — yadflow keeps no author list.
|
|
5
5
|
# Standalone workflow so it never collides with the Product-flavored yad-checks workflow.
|
|
6
|
+
#
|
|
7
|
+
# Gate scripts (#426): every job runs the BASE branch's copy of checks/, never the PR's own, so a PR that
|
|
8
|
+
# changes a gate script is still judged by the script already merged. A script the base does not have yet
|
|
9
|
+
# (the PR that first installs the gates, or a `yad update` that adds one) runs from the PR, with a note.
|
|
10
|
+
# The base's script runs with THIS file's call: keep every call one the previous release's script accepts.
|
|
11
|
+
# This file itself still comes from the PR: protect checks/ and the CI files with a CODEOWNERS rule and
|
|
12
|
+
# a required Code Owner review (docs/branch-protection.md, "Who may change the gates").
|
|
6
13
|
name: yad-verified-commits
|
|
7
14
|
on:
|
|
8
15
|
pull_request:
|
|
9
16
|
branches: ["**"]
|
|
10
17
|
|
|
18
|
+
# A newer push to the same pull request cancels this workflow's older run (#428): only the newest commit
|
|
19
|
+
# can be merged, and every gate here re-reads the whole PR range, so the older run checks nothing it misses.
|
|
20
|
+
concurrency:
|
|
21
|
+
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
|
|
22
|
+
cancel-in-progress: true
|
|
23
|
+
|
|
11
24
|
permissions:
|
|
12
25
|
contents: read
|
|
13
26
|
|
|
14
27
|
jobs:
|
|
15
28
|
verified-commits:
|
|
16
29
|
runs-on: ubuntu-latest
|
|
30
|
+
timeout-minutes: 10
|
|
17
31
|
env:
|
|
18
32
|
GH_TOKEN: ${{ github.token }} # read-only: gh api commits/<sha> for the Verified badge
|
|
19
33
|
steps:
|
|
20
|
-
- uses: actions/checkout@
|
|
21
|
-
with: { fetch-depth: 0 }
|
|
22
|
-
-
|
|
34
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
35
|
+
with: { fetch-depth: 0, persist-credentials: false }
|
|
36
|
+
- name: Gate scripts from the base branch (#426)
|
|
37
|
+
env: { YAD_BASE: "${{ github.base_ref }}" }
|
|
38
|
+
run: |
|
|
39
|
+
YAD_CHECKS="$RUNNER_TEMP/yad-base-checks/checks"
|
|
40
|
+
(
|
|
41
|
+
set -euo pipefail
|
|
42
|
+
b="origin/${YAD_BASE}"; d="${YAD_CHECKS%/checks}"
|
|
43
|
+
rm -rf "$d"; mkdir -p "$YAD_CHECKS"
|
|
44
|
+
git rev-parse --verify --quiet "${b}^{commit}" > /dev/null || { echo "FAIL [base-checks]: ${b} is not in this checkout, so the gate scripts cannot be read from the base branch. Check the code out with its full history." >&2; exit 1; }
|
|
45
|
+
t="$(git ls-tree "$b" checks)"
|
|
46
|
+
case "$t" in
|
|
47
|
+
"") on_base=0 ;;
|
|
48
|
+
"040000 tree "*) git archive "$b" checks | tar -x -C "$d"; on_base=1 ;;
|
|
49
|
+
*) echo "FAIL [base-checks]: checks on ${b} is not a folder, so the gate scripts cannot be read from it. Make checks/ a plain folder on the base branch." >&2; exit 1 ;;
|
|
50
|
+
esac
|
|
51
|
+
git ls-tree -z HEAD checks/ > "$d/.pr"
|
|
52
|
+
n=0
|
|
53
|
+
while IFS= read -r -d '' e; do
|
|
54
|
+
m="${e%% *}"; p="${e#*$'\t'}"; o="${e#* * }"; o="${o%%$'\t'*}"; s="${p//[[:cntrl:]]/?}"
|
|
55
|
+
if [ -e "$d/$p" ] || [ -L "$d/$p" ]; then continue; fi
|
|
56
|
+
case "$m" in
|
|
57
|
+
100644 | 100755) git cat-file blob "$o" > "$d/$p"; if [ "$m" = 100755 ]; then chmod +x "$d/$p"; fi ;;
|
|
58
|
+
*) printf 'note: %s in this PR is not a plain file, so it is not run (#426)\n' "$s"; continue ;;
|
|
59
|
+
esac
|
|
60
|
+
n=$((n + 1))
|
|
61
|
+
if [ "$on_base" = 1 ]; then printf 'note: %s is not on %s yet, so the copy from this PR runs (#426)\n' "$s" "$YAD_BASE"; fi
|
|
62
|
+
done < "$d/.pr"
|
|
63
|
+
rm -f "$d/.pr"
|
|
64
|
+
if [ "$n" = 1 ]; then w="1 file"; else w="$n files"; fi
|
|
65
|
+
if [ "$on_base" = 0 ]; then printf 'note: %s has no checks/ folder yet, so the gate scripts from this PR run: %s (#426)\n' "$YAD_BASE" "$w"; fi
|
|
66
|
+
)
|
|
67
|
+
echo "YAD_CHECKS=$YAD_CHECKS" >> "$GITHUB_ENV"
|
|
68
|
+
- run: bash "$YAD_CHECKS/verified-commits.sh" "origin/${{ github.base_ref }}"
|