jonah-fleet 1.5.0 → 1.6.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.
@@ -36,6 +36,8 @@ jobs:
36
36
  uses: actions/checkout@v4
37
37
  with:
38
38
  fetch-depth: 0
39
+ token: ${{ secrets.GH_PAT || github.token }}
40
+
39
41
 
40
42
  - name: Setup Node.js
41
43
  uses: actions/setup-node@v4
@@ -170,3 +172,34 @@ jobs:
170
172
  fi
171
173
  fi
172
174
  fi
175
+
176
+ - name: Commit and push run log directly to main
177
+ if: always()
178
+ env:
179
+ GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
180
+ run: |
181
+ LATEST_LOG=$(ls -t .github/prompts/logs/autowork/*.md 2>/dev/null | head -n 1)
182
+ if [ -n "$LATEST_LOG" ] && [ -f "$LATEST_LOG" ]; then
183
+ TMP_LOG_FILE=$(mktemp)
184
+ cp "$LATEST_LOG" "$TMP_LOG_FILE"
185
+ LOG_REL_PATH="$LATEST_LOG"
186
+ LOG_NAME=$(basename "$LATEST_LOG" .md)
187
+
188
+ git fetch origin main:main || git fetch origin main || true
189
+ git checkout main || git checkout -B main origin/main || true
190
+
191
+ mkdir -p "$(dirname "$LOG_REL_PATH")"
192
+ cp "$TMP_LOG_FILE" "$LOG_REL_PATH"
193
+ rm -f "$TMP_LOG_FILE"
194
+
195
+ git add "$LOG_REL_PATH"
196
+ if ! git diff --cached --quiet; then
197
+ git commit -m "docs(log): record autowork run ${LOG_NAME} [skip ci]" || true
198
+ if [ -n "$GH_TOKEN" ]; then
199
+ git push "https://x-access-token:${GH_TOKEN}@github.com/${GITHUB_REPOSITORY}.git" main || git push origin main || true
200
+ else
201
+ git push origin main || true
202
+ fi
203
+ fi
204
+ fi
205
+
@@ -41,6 +41,8 @@ jobs:
41
41
  uses: actions/checkout@v4
42
42
  with:
43
43
  fetch-depth: 0
44
+ token: ${{ secrets.GH_PAT || github.token }}
45
+
44
46
 
45
47
  - name: Setup Node.js
46
48
  uses: actions/setup-node@v4
@@ -26,6 +26,8 @@ jobs:
26
26
  uses: actions/checkout@v4
27
27
  with:
28
28
  fetch-depth: 0
29
+ token: ${{ secrets.GH_PAT || github.token }}
30
+
29
31
 
30
32
  - name: Setup Node.js
31
33
  uses: actions/setup-node@v4
@@ -49,6 +49,8 @@ jobs:
49
49
  uses: actions/checkout@v4
50
50
  with:
51
51
  fetch-depth: 0
52
+ token: ${{ secrets.GH_PAT || github.token }}
53
+
52
54
 
53
55
  - name: Setup Node.js
54
56
  if: steps.pick.outputs.skip != 'true'