-
Notifications
You must be signed in to change notification settings - Fork 11
52 lines (45 loc) · 1.69 KB
/
Copy pathupdate-progress.yml
File metadata and controls
52 lines (45 loc) · 1.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Update PROGRESS.md
on:
push:
branches: [main]
permissions:
contents: write
jobs:
update-progress:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Use beads-sync JSONL if available
run: |
# The beads-sync branch may have fresher issues.jsonl than main.
# bd sync exports to beads-sync but assume-unchanged can prevent
# those changes from reaching main via normal commits.
# Fetch and overlay the beads-sync copy as a safety net.
if git rev-parse --verify origin/beads-sync >/dev/null 2>&1; then
echo "Found beads-sync branch, checking for fresher JSONL..."
sync_jsonl=$(git show origin/beads-sync:.beads/issues.jsonl 2>/dev/null || true)
if [ -n "$sync_jsonl" ]; then
echo "$sync_jsonl" > .beads/issues.jsonl
echo "Using issues.jsonl from beads-sync branch"
else
echo "No issues.jsonl on beads-sync, using main copy"
fi
else
echo "No beads-sync branch on remote, using main copy"
fi
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Regenerate PROGRESS.md
run: python .beads/generate_progress.py
- name: Commit and push if changed
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add .beads/PROGRESS.md .beads/issues.jsonl
if ! git diff --cached --quiet; then
git commit -m "Auto-update PROGRESS.md"
git push
fi