project-auto-wizard 0.14.0 → 0.15.1
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/README.ja.md +3 -1
- package/README.ko.md +3 -1
- package/README.md +4 -2
- package/README.zh-CN.md +3 -1
- package/package.json +1 -1
- package/payload/config/breaking-changes.json +31 -5
- package/payload/config/wizard-prompts.yml +0 -4
- package/payload/scripts/changelog_manager.py +8 -8
- package/payload/scripts/messages.py +460 -24
- package/payload/scripts/version_manager.py +102 -73
- package/payload/version.yml.template +2 -2
- package/payload/workflows/common/PROJECT-COMMON-AI-PR-SUMMARY.yaml +9 -4
- package/payload/workflows/common/PROJECT-COMMON-AUTO-CHANGELOG-CONTROL.yaml +62 -30
- package/payload/workflows/common/PROJECT-COMMON-README-VERSION-UPDATE.yaml +96 -44
- package/payload/workflows/common/PROJECT-COMMON-RELEASE-PUBLISH.yaml +79 -35
- package/payload/workflows/common/PROJECT-COMMON-VERSION-CONTROL.yaml +71 -35
- package/payload/workflows/flutter/PROJECT-FLUTTER-ANDROID-FIREBASE-CICD.yaml +24 -8
- package/payload/workflows/flutter/PROJECT-FLUTTER-ANDROID-PLAYSTORE-CICD.yaml +29 -10
- package/payload/workflows/flutter/PROJECT-FLUTTER-ANDROID-SELFHOSTED-CICD.yaml +57 -23
- package/payload/workflows/flutter/PROJECT-FLUTTER-ANDROID-TEST-APK.yaml +155 -72
- package/payload/workflows/flutter/PROJECT-FLUTTER-APP-BUILD-TRIGGER.yaml +49 -20
- package/payload/workflows/flutter/PROJECT-FLUTTER-CI.yaml +162 -62
- package/payload/workflows/flutter/PROJECT-FLUTTER-IOS-TEST-TESTFLIGHT.yaml +184 -87
- package/payload/workflows/flutter/PROJECT-FLUTTER-IOS-TESTFLIGHT.yaml +38 -15
- package/payload/workflows/go/PROJECT-GO-CI.yaml +14 -5
- package/payload/workflows/go/PROJECT-GO-PR-PREVIEW.yaml +375 -120
- package/payload/workflows/go/PROJECT-GO-SIMPLE-CICD.yaml +9 -4
- package/payload/workflows/python/PROJECT-PYTHON-CI.yaml +12 -4
- package/payload/workflows/python/PROJECT-PYTHON-PR-PREVIEW.yaml +375 -120
- package/payload/workflows/python/PROJECT-PYTHON-SIMPLE-CICD.yaml +9 -4
- package/payload/workflows/react/PROJECT-REACT-CI.yaml +38 -9
- package/payload/workflows/react/PROJECT-REACT-CICD.yaml +19 -5
- package/payload/workflows/spring/PROJECT-SPRING-CI.yml +71 -35
- package/payload/workflows/spring/server-deploy/PROJECT-SPRING-NONSTOP-NGINX-CICD.yaml +9 -6
- package/payload/workflows/spring/server-deploy/PROJECT-SPRING-NONSTOP-TRAEFIK-CICD.yaml +7 -4
- package/payload/workflows/spring/server-deploy/PROJECT-SPRING-PR-PREVIEW.yaml +425 -144
- package/payload/workflows/spring/server-deploy/PROJECT-SPRING-SIMPLE-CICD.yaml +7 -4
- package/src/cli/args.js +17 -7
- package/src/commands/doctor.js +16 -0
- package/src/commands/dry-run.js +10 -1
- package/src/commands/full.js +5 -2
- package/src/commands/interactive.js +4 -1
- package/src/commands/status.js +14 -1
- package/src/core/copy/readme.js +58 -2
- package/src/core/copy/simple.js +31 -0
- package/src/core/copy/workflows.js +2 -2
- package/src/core/deploy-style.js +1 -1
- package/src/core/detect.js +3 -2
- package/src/core/types.js +15 -8
- package/src/core/version-yml.js +52 -6
- package/src/i18n/catalog/en/cli.js +1 -0
- package/src/i18n/catalog/en/commands.js +9 -0
- package/src/i18n/catalog/en/copy.js +1 -0
- package/src/i18n/catalog/en/core2.js +3 -0
- package/src/i18n/catalog/ko/cli.js +1 -0
- package/src/i18n/catalog/ko/commands.js +9 -0
- package/src/i18n/catalog/ko/copy.js +1 -0
- package/src/i18n/catalog/ko/core2.js +3 -0
- package/src/index.js +8 -4
- package/src/ui/env-plan.js +1 -1
- package/src/ui/prompts.js +7 -3
- package/src/ui/summary.js +1 -1
- package/payload/workflows/next/PROJECT-NEXT-CI.yaml +0 -241
- package/payload/workflows/next/PROJECT-NEXT-CICD.yaml +0 -330
|
@@ -94,6 +94,7 @@ jobs:
|
|
|
94
94
|
- name: Load messages
|
|
95
95
|
working-directory: ${{ github.workspace }}
|
|
96
96
|
run: |
|
|
97
|
+
[ -f .paw-msg/.github/scripts/messages.py ] || { echo "::error::messages.py is missing; rerun \`npx project-auto-wizard --mode full --force\`"; exit 1; }
|
|
97
98
|
cp .paw-msg/.github/scripts/messages.py "$RUNNER_TEMP/paw_messages.py"
|
|
98
99
|
LANG_CODE=$(cd .paw-msg && python3 "$RUNNER_TEMP/paw_messages.py" lang)
|
|
99
100
|
rm -rf .paw-msg
|
|
@@ -104,14 +105,18 @@ jobs:
|
|
|
104
105
|
- name: Verify the branch exists up front
|
|
105
106
|
id: verify_branch
|
|
106
107
|
uses: actions/github-script@v9
|
|
108
|
+
env:
|
|
109
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
110
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_PR_NUMBER: ${{ github.event.client_payload.pr_number }}
|
|
111
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
107
112
|
with:
|
|
108
113
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
109
114
|
script: |
|
|
110
115
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
111
116
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
112
|
-
const branchName =
|
|
113
|
-
const prNumber =
|
|
114
|
-
const runId =
|
|
117
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
118
|
+
const prNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_PR_NUMBER;
|
|
119
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
115
120
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
116
121
|
|
|
117
122
|
console.log(msg('ios_test_tf.branch_check_log', { branch: branchName }));
|
|
@@ -162,16 +167,21 @@ jobs:
|
|
|
162
167
|
if: github.event.client_payload.pr_number != ''
|
|
163
168
|
continue-on-error: true
|
|
164
169
|
uses: actions/github-script@v9
|
|
170
|
+
env:
|
|
171
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
172
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
173
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_PR_NUMBER: ${{ github.event.client_payload.pr_number }}
|
|
174
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
165
175
|
with:
|
|
166
176
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
167
177
|
script: |
|
|
168
178
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
169
179
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
170
180
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
171
|
-
const prNumber = parseInt(
|
|
172
|
-
const branchName =
|
|
173
|
-
const buildNumber =
|
|
174
|
-
const runId =
|
|
181
|
+
const prNumber = parseInt(process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_PR_NUMBER);
|
|
182
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
183
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
184
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
175
185
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
176
186
|
const startTime = Date.now();
|
|
177
187
|
|
|
@@ -227,6 +237,7 @@ jobs:
|
|
|
227
237
|
branch_name: ${{ steps.issue_info.outputs.branch_name }}
|
|
228
238
|
pr_number: ${{ steps.test_version.outputs.pr_number }}
|
|
229
239
|
commit_hash: ${{ steps.release_notes.outputs.commit_hash }}
|
|
240
|
+
commit_sha: ${{ steps.release_notes.outputs.commit_sha }}
|
|
230
241
|
|
|
231
242
|
steps:
|
|
232
243
|
# Fetch the message catalog from the triggering ref first — the feature branch being built may predate it
|
|
@@ -240,8 +251,10 @@ jobs:
|
|
|
240
251
|
sparse-checkout-cone-mode: false
|
|
241
252
|
|
|
242
253
|
- name: Load messages
|
|
254
|
+
id: load_messages
|
|
243
255
|
working-directory: ${{ github.workspace }}
|
|
244
256
|
run: |
|
|
257
|
+
[ -f .paw-msg/.github/scripts/messages.py ] || { echo "::error::messages.py is missing; rerun \`npx project-auto-wizard --mode full --force\`"; exit 1; }
|
|
245
258
|
cp .paw-msg/.github/scripts/messages.py "$RUNNER_TEMP/paw_messages.py"
|
|
246
259
|
LANG_CODE=$(cd .paw-msg && python3 "$RUNNER_TEMP/paw_messages.py" lang)
|
|
247
260
|
rm -rf .paw-msg
|
|
@@ -256,7 +269,9 @@ jobs:
|
|
|
256
269
|
ref: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref }}
|
|
257
270
|
|
|
258
271
|
- name: Pull latest changes
|
|
259
|
-
|
|
272
|
+
env:
|
|
273
|
+
PAW_BRANCH_NAME: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref_name }}
|
|
274
|
+
run: git pull origin "$PAW_BRANCH_NAME"
|
|
260
275
|
|
|
261
276
|
# Report every missing setting up front, before importing certificates or building — otherwise the macOS runner builds for a long time and fails at an unrelated step
|
|
262
277
|
- name: Validate deploy settings
|
|
@@ -301,18 +316,22 @@ jobs:
|
|
|
301
316
|
env:
|
|
302
317
|
SECRETS_XCCONFIG_CONTENT: ${{ secrets.SECRETS_XCCONFIG }}
|
|
303
318
|
run: |
|
|
319
|
+
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
304
320
|
mkdir -p ios/Flutter
|
|
305
321
|
if [ -n "$SECRETS_XCCONFIG_CONTENT" ]; then
|
|
306
322
|
echo "$SECRETS_XCCONFIG_CONTENT" > ios/Flutter/Secrets.xcconfig
|
|
307
|
-
|
|
323
|
+
m wf_flutter.secrets_xcconfig_created_ok
|
|
308
324
|
else
|
|
309
325
|
echo "// No secrets provided" > ios/Flutter/Secrets.xcconfig
|
|
310
|
-
|
|
326
|
+
m wf_flutter.secrets_xcconfig_empty
|
|
311
327
|
fi
|
|
312
328
|
|
|
313
329
|
- name: Set test build version
|
|
314
330
|
id: test_version
|
|
315
331
|
working-directory: ${{ github.workspace }} # version_manager.py must read version.yml at the repo root
|
|
332
|
+
env:
|
|
333
|
+
PAW_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
334
|
+
PAW_PR_NUMBER: ${{ github.event.client_payload.pr_number }}
|
|
316
335
|
run: |
|
|
317
336
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
318
337
|
# Get the version through version_manager.py (same approach as the production workflow)
|
|
@@ -321,8 +340,8 @@ jobs:
|
|
|
321
340
|
|
|
322
341
|
# For repository_dispatch events, use the PR number as the build number
|
|
323
342
|
if [ "${{ github.event_name }}" == "repository_dispatch" ]; then
|
|
324
|
-
BUILD_NUMBER="$
|
|
325
|
-
PR_NUMBER="$
|
|
343
|
+
BUILD_NUMBER="$PAW_BUILD_NUMBER"
|
|
344
|
+
PR_NUMBER="$PAW_PR_NUMBER"
|
|
326
345
|
m ios_test_tf.event_dispatch
|
|
327
346
|
m ios_test_tf.event_pr_number pr="$PR_NUMBER"
|
|
328
347
|
m ios_test_tf.event_build_number_pr build="$BUILD_NUMBER"
|
|
@@ -339,14 +358,18 @@ jobs:
|
|
|
339
358
|
|
|
340
359
|
- name: Extract issue info from the branch name
|
|
341
360
|
id: issue_info
|
|
361
|
+
env:
|
|
362
|
+
PAW_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
363
|
+
PAW_ISSUE_NUMBER: ${{ github.event.client_payload.issue_number }}
|
|
364
|
+
PAW_REF_NAME: ${{ github.ref_name }}
|
|
342
365
|
run: |
|
|
343
366
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
344
367
|
# For repository_dispatch, take the branch name from client_payload
|
|
345
368
|
if [ "${{ github.event_name }}" == "repository_dispatch" ]; then
|
|
346
|
-
BRANCH_NAME="$
|
|
347
|
-
ISSUE_NUMBER="$
|
|
369
|
+
BRANCH_NAME="$PAW_BRANCH_NAME"
|
|
370
|
+
ISSUE_NUMBER="$PAW_ISSUE_NUMBER"
|
|
348
371
|
else
|
|
349
|
-
BRANCH_NAME="$
|
|
372
|
+
BRANCH_NAME="$PAW_REF_NAME"
|
|
350
373
|
# Extract the issue number from the branch name (`<date>_#<number>_...` format)
|
|
351
374
|
ISSUE_NUMBER=$(echo "$BRANCH_NAME" | sed -n 's/.*#\([0-9]*\).*/\1/p')
|
|
352
375
|
fi
|
|
@@ -387,15 +410,20 @@ jobs:
|
|
|
387
410
|
- name: Generate release notes
|
|
388
411
|
id: release_notes
|
|
389
412
|
working-directory: ${{ github.workspace }} # final_release_notes.txt (paired with the upload step) is relative to the repo root
|
|
413
|
+
env:
|
|
414
|
+
PAW_BRANCH_NAME: ${{ steps.issue_info.outputs.branch_name }}
|
|
415
|
+
PAW_ISSUE_TITLE: ${{ steps.issue_info.outputs.issue_title }}
|
|
390
416
|
run: |
|
|
391
417
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
392
418
|
BUILD_NUMBER="${{ steps.test_version.outputs.build_number }}"
|
|
393
|
-
BRANCH_NAME="$
|
|
394
|
-
|
|
419
|
+
BRANCH_NAME="$PAW_BRANCH_NAME"
|
|
420
|
+
# github.sha is the default-branch commit for repository_dispatch; report the commit actually checked out
|
|
421
|
+
COMMIT_SHA=$(git rev-parse HEAD)
|
|
395
422
|
COMMIT_SHORT=$(echo "$COMMIT_SHA" | cut -c1-7)
|
|
396
|
-
BUILD_DATE=$(date '+%Y-%m-%d %H:%M:%S')
|
|
423
|
+
BUILD_DATE=$(date -u '+%Y-%m-%d %H:%M:%S UTC')
|
|
397
424
|
|
|
398
425
|
echo "commit_hash=$COMMIT_SHORT" >> $GITHUB_OUTPUT
|
|
426
|
+
echo "commit_sha=$COMMIT_SHA" >> $GITHUB_OUTPUT
|
|
399
427
|
|
|
400
428
|
{
|
|
401
429
|
m ios_test_tf.notes_build build="$BUILD_NUMBER"
|
|
@@ -409,7 +437,7 @@ jobs:
|
|
|
409
437
|
# Add the issue info when available
|
|
410
438
|
if [ -n "${{ steps.issue_info.outputs.issue_number }}" ]; then
|
|
411
439
|
ISSUE_NUMBER="${{ steps.issue_info.outputs.issue_number }}"
|
|
412
|
-
ISSUE_TITLE="$
|
|
440
|
+
ISSUE_TITLE="$PAW_ISSUE_TITLE"
|
|
413
441
|
ISSUE_URL="${{ steps.issue_info.outputs.issue_url }}"
|
|
414
442
|
|
|
415
443
|
{
|
|
@@ -444,19 +472,25 @@ jobs:
|
|
|
444
472
|
retention-days: 1
|
|
445
473
|
|
|
446
474
|
- name: Progress update - prepare failed
|
|
447
|
-
if: failure() && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
475
|
+
if: failure() && steps.load_messages.outcome == 'success' && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
448
476
|
uses: actions/github-script@v9
|
|
477
|
+
env:
|
|
478
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
479
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
480
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
481
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
482
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME: ${{ needs.notify-start.outputs.start_time }}
|
|
449
483
|
with:
|
|
450
484
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
451
485
|
script: |
|
|
452
486
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
453
487
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
454
488
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
455
|
-
const commentId = parseInt(
|
|
456
|
-
const startTime = parseInt(
|
|
457
|
-
const branchName =
|
|
458
|
-
const buildNumber =
|
|
459
|
-
const runId =
|
|
489
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
490
|
+
const startTime = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME);
|
|
491
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
492
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
493
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
460
494
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
461
495
|
|
|
462
496
|
const now = Date.now();
|
|
@@ -523,8 +557,10 @@ jobs:
|
|
|
523
557
|
sparse-checkout-cone-mode: false
|
|
524
558
|
|
|
525
559
|
- name: Load messages
|
|
560
|
+
id: load_messages
|
|
526
561
|
working-directory: ${{ github.workspace }}
|
|
527
562
|
run: |
|
|
563
|
+
[ -f .paw-msg/.github/scripts/messages.py ] || { echo "::error::messages.py is missing; rerun \`npx project-auto-wizard --mode full --force\`"; exit 1; }
|
|
528
564
|
cp .paw-msg/.github/scripts/messages.py "$RUNNER_TEMP/paw_messages.py"
|
|
529
565
|
LANG_CODE=$(cd .paw-msg && python3 "$RUNNER_TEMP/paw_messages.py" lang)
|
|
530
566
|
rm -rf .paw-msg
|
|
@@ -537,18 +573,25 @@ jobs:
|
|
|
537
573
|
id: progress_step1
|
|
538
574
|
if: github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
539
575
|
uses: actions/github-script@v9
|
|
576
|
+
env:
|
|
577
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
578
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
579
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
580
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
581
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME: ${{ needs.notify-start.outputs.start_time }}
|
|
582
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION: ${{ needs.prepare-test-build.outputs.version }}
|
|
540
583
|
with:
|
|
541
584
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
542
585
|
script: |
|
|
543
586
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
544
587
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
545
588
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
546
|
-
const commentId = parseInt(
|
|
547
|
-
const startTime = parseInt(
|
|
548
|
-
const branchName =
|
|
549
|
-
const buildNumber =
|
|
550
|
-
const version =
|
|
551
|
-
const runId =
|
|
589
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
590
|
+
const startTime = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME);
|
|
591
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
592
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
593
|
+
const version = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION;
|
|
594
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
552
595
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
553
596
|
|
|
554
597
|
const now = Date.now();
|
|
@@ -595,7 +638,9 @@ jobs:
|
|
|
595
638
|
ref: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref }}
|
|
596
639
|
|
|
597
640
|
- name: Pull latest changes
|
|
598
|
-
|
|
641
|
+
env:
|
|
642
|
+
PAW_BRANCH_NAME: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref_name }}
|
|
643
|
+
run: git pull origin "$PAW_BRANCH_NAME"
|
|
599
644
|
|
|
600
645
|
- name: Select Xcode version
|
|
601
646
|
run: sudo xcode-select -s /Applications/Xcode_${{ env.XCODE_VERSION }}.app/Contents/Developer
|
|
@@ -605,16 +650,21 @@ jobs:
|
|
|
605
650
|
# xcode-select alone does not propagate to subprocesses, so set it explicitly
|
|
606
651
|
DEVELOPER_DIR: /Applications/Xcode_${{ env.XCODE_VERSION }}.app/Contents/Developer
|
|
607
652
|
run: |
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
653
|
+
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
654
|
+
m wf_flutter.xcode_platform_check
|
|
655
|
+
if ls "$DEVELOPER_DIR/Platforms/iPhoneOS.platform/" 2>/dev/null; then
|
|
656
|
+
m wf_flutter.xcode_platform_exists
|
|
657
|
+
else
|
|
658
|
+
m wf_flutter.xcode_platform_missing
|
|
659
|
+
fi
|
|
660
|
+
m wf_flutter.xcode_install_pkgs
|
|
611
661
|
sudo installer -pkg /Applications/Xcode_${{ env.XCODE_VERSION }}.app/Contents/Resources/Packages/MobileDevice.pkg -target /
|
|
612
662
|
sudo installer -pkg /Applications/Xcode_${{ env.XCODE_VERSION }}.app/Contents/Resources/Packages/MobileDeviceDevelopment.pkg -target /
|
|
613
|
-
|
|
663
|
+
m wf_flutter.xcode_license
|
|
614
664
|
sudo xcodebuild -license accept
|
|
615
|
-
|
|
665
|
+
m wf_flutter.xcode_init
|
|
616
666
|
xcrun simctl list >/dev/null 2>&1 || true
|
|
617
|
-
|
|
667
|
+
m wf_flutter.xcode_download
|
|
618
668
|
xcodebuild -downloadPlatform iOS
|
|
619
669
|
|
|
620
670
|
- name: Download project files
|
|
@@ -627,14 +677,15 @@ jobs:
|
|
|
627
677
|
env:
|
|
628
678
|
ENV_CONTENT: ${{ secrets.ENV_FILE || secrets.ENV }}
|
|
629
679
|
run: |
|
|
680
|
+
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
630
681
|
if [ "$ENV_MODE" = "dotenv" ]; then
|
|
631
682
|
printf '%s\n' "$ENV_CONTENT" > "$ENV_FILE_PATH"
|
|
632
|
-
|
|
683
|
+
m wf_flutter.env_file_created file="$ENV_FILE_PATH"
|
|
633
684
|
elif [ -n "$ENV_CONTENT" ]; then
|
|
634
685
|
DART_DEFINE_FILE="$RUNNER_TEMP/dart-define.env"
|
|
635
686
|
printf '%s\n' "$ENV_CONTENT" > "$DART_DEFINE_FILE"
|
|
636
687
|
echo "DART_DEFINE_FILE=$DART_DEFINE_FILE" >> "$GITHUB_ENV"
|
|
637
|
-
|
|
688
|
+
m wf_flutter.dart_define_prepared
|
|
638
689
|
fi
|
|
639
690
|
|
|
640
691
|
- name: Set up Flutter
|
|
@@ -676,7 +727,7 @@ jobs:
|
|
|
676
727
|
fi
|
|
677
728
|
|
|
678
729
|
- name: Import Code-Signing Certificates
|
|
679
|
-
uses: Apple-Actions/import-codesign-certs@
|
|
730
|
+
uses: Apple-Actions/import-codesign-certs@v7
|
|
680
731
|
with:
|
|
681
732
|
p12-file-base64: ${{ secrets.APPLE_CERTIFICATE_BASE64 }}
|
|
682
733
|
p12-password: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
|
|
@@ -737,13 +788,15 @@ jobs:
|
|
|
737
788
|
-exportOptionsPlist ExportOptions.plist
|
|
738
789
|
|
|
739
790
|
- name: Create build metadata file
|
|
791
|
+
env:
|
|
792
|
+
PAW_BRANCH_NAME: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref_name }}
|
|
740
793
|
run: |
|
|
741
794
|
cat > build-metadata.json << EOF
|
|
742
795
|
{
|
|
743
796
|
"pr_number": "${{ needs.prepare-test-build.outputs.pr_number }}",
|
|
744
797
|
"build_number": "${{ needs.prepare-test-build.outputs.build_number }}",
|
|
745
798
|
"issue_number": "${{ needs.prepare-test-build.outputs.issue_number }}",
|
|
746
|
-
"branch_name": "$
|
|
799
|
+
"branch_name": "$PAW_BRANCH_NAME"
|
|
747
800
|
}
|
|
748
801
|
EOF
|
|
749
802
|
cat build-metadata.json
|
|
@@ -761,19 +814,27 @@ jobs:
|
|
|
761
814
|
id: progress_step2
|
|
762
815
|
if: success() && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
763
816
|
uses: actions/github-script@v9
|
|
817
|
+
env:
|
|
818
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
819
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
820
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
821
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
822
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION: ${{ needs.prepare-test-build.outputs.version }}
|
|
823
|
+
PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_ELAPSED: ${{ steps.progress_step1.outputs.elapsed }}
|
|
824
|
+
PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_END_TIME: ${{ steps.progress_step1.outputs.end_time }}
|
|
764
825
|
with:
|
|
765
826
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
766
827
|
script: |
|
|
767
828
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
768
829
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
769
830
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
770
|
-
const commentId = parseInt(
|
|
771
|
-
const step1EndTime = parseInt(
|
|
772
|
-
const step1Elapsed =
|
|
773
|
-
const branchName =
|
|
774
|
-
const buildNumber =
|
|
775
|
-
const version =
|
|
776
|
-
const runId =
|
|
831
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
832
|
+
const step1EndTime = parseInt(process.env.PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_END_TIME);
|
|
833
|
+
const step1Elapsed = process.env.PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_ELAPSED;
|
|
834
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
835
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
836
|
+
const version = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION;
|
|
837
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
777
838
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
778
839
|
|
|
779
840
|
const now = Date.now();
|
|
@@ -816,23 +877,33 @@ jobs:
|
|
|
816
877
|
core.setOutput('end_time', now.toString());
|
|
817
878
|
|
|
818
879
|
- name: Update the progress comment on build failure
|
|
819
|
-
if: failure() && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
880
|
+
if: failure() && steps.load_messages.outcome == 'success' && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
820
881
|
uses: actions/github-script@v9
|
|
882
|
+
env:
|
|
883
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
884
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
885
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
886
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
887
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME: ${{ needs.notify-start.outputs.start_time }}
|
|
888
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH: ${{ needs.prepare-test-build.outputs.commit_hash }}
|
|
889
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION: ${{ needs.prepare-test-build.outputs.version }}
|
|
890
|
+
PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_ELAPSED: ${{ steps.progress_step1.outputs.elapsed }}
|
|
891
|
+
PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_END_TIME: ${{ steps.progress_step1.outputs.end_time }}
|
|
821
892
|
with:
|
|
822
893
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
823
894
|
script: |
|
|
824
895
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
825
896
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
826
897
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
827
|
-
const commentId = parseInt(
|
|
828
|
-
const startTime = parseInt(
|
|
829
|
-
const step1EndTime = parseInt(
|
|
830
|
-
const step1Elapsed =
|
|
831
|
-
const branchName =
|
|
832
|
-
const buildNumber =
|
|
833
|
-
const version =
|
|
834
|
-
const commitHash =
|
|
835
|
-
const runId =
|
|
898
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
899
|
+
const startTime = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME);
|
|
900
|
+
const step1EndTime = parseInt(process.env.PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_END_TIME) || 0;
|
|
901
|
+
const step1Elapsed = process.env.PAW_IN_STEPS_PROGRESS_STEP1_OUTPUTS_ELAPSED;
|
|
902
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
903
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
904
|
+
const version = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION;
|
|
905
|
+
const commitHash = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH;
|
|
906
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
836
907
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
837
908
|
|
|
838
909
|
const now = Date.now();
|
|
@@ -899,8 +970,10 @@ jobs:
|
|
|
899
970
|
sparse-checkout-cone-mode: false
|
|
900
971
|
|
|
901
972
|
- name: Load messages
|
|
973
|
+
id: load_messages
|
|
902
974
|
working-directory: ${{ github.workspace }}
|
|
903
975
|
run: |
|
|
976
|
+
[ -f .paw-msg/.github/scripts/messages.py ] || { echo "::error::messages.py is missing; rerun \`npx project-auto-wizard --mode full --force\`"; exit 1; }
|
|
904
977
|
cp .paw-msg/.github/scripts/messages.py "$RUNNER_TEMP/paw_messages.py"
|
|
905
978
|
LANG_CODE=$(cd .paw-msg && python3 "$RUNNER_TEMP/paw_messages.py" lang)
|
|
906
979
|
rm -rf .paw-msg
|
|
@@ -956,7 +1029,7 @@ jobs:
|
|
|
956
1029
|
printf 'source "https://rubygems.org"\ngem "fastlane"\ngem "multi_json"\n' > Gemfile
|
|
957
1030
|
fi
|
|
958
1031
|
bundle install
|
|
959
|
-
|
|
1032
|
+
m flutter_a.fastlane_installed_bundler
|
|
960
1033
|
|
|
961
1034
|
- name: Upload to TestFlight
|
|
962
1035
|
env:
|
|
@@ -966,7 +1039,7 @@ jobs:
|
|
|
966
1039
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
967
1040
|
# Find the IPA file
|
|
968
1041
|
IPA_PATH=$(find "$GITHUB_WORKSPACE/${FLUTTER_PROJECT_DIR}/ios/build/ipa" -name "*.ipa" | head -1)
|
|
969
|
-
|
|
1042
|
+
m wf_flutter.ipa_found path="$IPA_PATH"
|
|
970
1043
|
|
|
971
1044
|
if [ ! -f "$IPA_PATH" ]; then
|
|
972
1045
|
m ios_test_tf.ipa_missing
|
|
@@ -977,7 +1050,7 @@ jobs:
|
|
|
977
1050
|
# Prepare release notes (final_release_notes.txt is relative to the repo root — use an absolute path since working-directory is FLUTTER_PROJECT_DIR)
|
|
978
1051
|
if [ -f "$GITHUB_WORKSPACE/final_release_notes.txt" ]; then
|
|
979
1052
|
RELEASE_NOTES=$(cat "$GITHUB_WORKSPACE/final_release_notes.txt")
|
|
980
|
-
|
|
1053
|
+
m wf_flutter.release_notes_heading
|
|
981
1054
|
echo "$RELEASE_NOTES"
|
|
982
1055
|
else
|
|
983
1056
|
RELEASE_NOTES="$(m ios_test_tf.notes_build build="${{ needs.prepare-test-build.outputs.build_number }}")"
|
|
@@ -989,7 +1062,7 @@ jobs:
|
|
|
989
1062
|
export IPA_PATH="$IPA_PATH"
|
|
990
1063
|
export RELEASE_NOTES="$RELEASE_NOTES"
|
|
991
1064
|
|
|
992
|
-
|
|
1065
|
+
m wf_flutter.working_dir dir="$(pwd)"
|
|
993
1066
|
echo "🔧 IPA_PATH: $IPA_PATH"
|
|
994
1067
|
echo "🔧 API_KEY_PATH: $API_KEY_PATH"
|
|
995
1068
|
|
|
@@ -999,6 +1072,8 @@ jobs:
|
|
|
999
1072
|
|
|
1000
1073
|
- name: Notify TestFlight Upload Success
|
|
1001
1074
|
if: success()
|
|
1075
|
+
env:
|
|
1076
|
+
PAW_BRANCH_NAME: ${{ github.event_name == 'repository_dispatch' && github.event.client_payload.branch_name || github.ref_name }}
|
|
1002
1077
|
run: |
|
|
1003
1078
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
1004
1079
|
m ios_test_tf.upload_ok
|
|
@@ -1007,14 +1082,14 @@ jobs:
|
|
|
1007
1082
|
if [ -n "${{ needs.prepare-test-build.outputs.pr_number }}" ]; then
|
|
1008
1083
|
m ios_test_tf.upload_pr pr="${{ needs.prepare-test-build.outputs.pr_number }}"
|
|
1009
1084
|
fi
|
|
1010
|
-
m ios_test_tf.upload_branch branch="$
|
|
1011
|
-
m ios_test_tf.upload_commit sha="${{
|
|
1085
|
+
m ios_test_tf.upload_branch branch="$PAW_BRANCH_NAME"
|
|
1086
|
+
m ios_test_tf.upload_commit sha="${{ needs.prepare-test-build.outputs.commit_sha }}"
|
|
1012
1087
|
if [ -n "${{ needs.prepare-test-build.outputs.issue_url }}" ]; then
|
|
1013
1088
|
m ios_test_tf.upload_issue url="${{ needs.prepare-test-build.outputs.issue_url }}"
|
|
1014
1089
|
fi
|
|
1015
1090
|
|
|
1016
1091
|
- name: Notify on Failure
|
|
1017
|
-
if: failure()
|
|
1092
|
+
if: failure() && steps.load_messages.outcome == 'success'
|
|
1018
1093
|
run: |
|
|
1019
1094
|
m() { python3 "$PAW_MESSAGES_PY" get "$@"; }
|
|
1020
1095
|
m ios_test_tf.upload_failed
|
|
@@ -1023,22 +1098,33 @@ jobs:
|
|
|
1023
1098
|
- name: Final progress update - success
|
|
1024
1099
|
if: success() && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
1025
1100
|
uses: actions/github-script@v9
|
|
1101
|
+
env:
|
|
1102
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
1103
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
1104
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
1105
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP1_ELAPSED: ${{ needs.build-ios-test.outputs.step1_elapsed }}
|
|
1106
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_ELAPSED: ${{ needs.build-ios-test.outputs.step2_elapsed }}
|
|
1107
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_END_TIME: ${{ needs.build-ios-test.outputs.step2_end_time }}
|
|
1108
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
1109
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME: ${{ needs.notify-start.outputs.start_time }}
|
|
1110
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH: ${{ needs.prepare-test-build.outputs.commit_hash }}
|
|
1111
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION: ${{ needs.prepare-test-build.outputs.version }}
|
|
1026
1112
|
with:
|
|
1027
1113
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
1028
1114
|
script: |
|
|
1029
1115
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
1030
1116
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
1031
1117
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
1032
|
-
const commentId = parseInt(
|
|
1033
|
-
const startTime = parseInt(
|
|
1034
|
-
const step2EndTime = parseInt(
|
|
1035
|
-
const step1Elapsed =
|
|
1036
|
-
const step2Elapsed =
|
|
1037
|
-
const branchName =
|
|
1038
|
-
const buildNumber =
|
|
1039
|
-
const version =
|
|
1040
|
-
const commitHash =
|
|
1041
|
-
const runId =
|
|
1118
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
1119
|
+
const startTime = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME);
|
|
1120
|
+
const step2EndTime = parseInt(process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_END_TIME);
|
|
1121
|
+
const step1Elapsed = process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP1_ELAPSED;
|
|
1122
|
+
const step2Elapsed = process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_ELAPSED;
|
|
1123
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
1124
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
1125
|
+
const version = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION;
|
|
1126
|
+
const commitHash = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH;
|
|
1127
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
1042
1128
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
1043
1129
|
|
|
1044
1130
|
const now = Date.now();
|
|
@@ -1086,24 +1172,35 @@ jobs:
|
|
|
1086
1172
|
console.log(msg('ios_test_tf.log_all_done', { elapsed: totalElapsed }));
|
|
1087
1173
|
|
|
1088
1174
|
- name: Final progress update - failure
|
|
1089
|
-
if: failure() && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
1175
|
+
if: failure() && steps.load_messages.outcome == 'success' && github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '' && needs.notify-start.outputs.comment_id != ''
|
|
1090
1176
|
uses: actions/github-script@v9
|
|
1177
|
+
env:
|
|
1178
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME: ${{ github.event.client_payload.branch_name }}
|
|
1179
|
+
PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER: ${{ github.event.client_payload.build_number }}
|
|
1180
|
+
PAW_IN_GITHUB_RUN_ID: ${{ github.run_id }}
|
|
1181
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP1_ELAPSED: ${{ needs.build-ios-test.outputs.step1_elapsed }}
|
|
1182
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_ELAPSED: ${{ needs.build-ios-test.outputs.step2_elapsed }}
|
|
1183
|
+
PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_END_TIME: ${{ needs.build-ios-test.outputs.step2_end_time }}
|
|
1184
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID: ${{ needs.notify-start.outputs.comment_id }}
|
|
1185
|
+
PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME: ${{ needs.notify-start.outputs.start_time }}
|
|
1186
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH: ${{ needs.prepare-test-build.outputs.commit_hash }}
|
|
1187
|
+
PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION: ${{ needs.prepare-test-build.outputs.version }}
|
|
1091
1188
|
with:
|
|
1092
1189
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
1093
1190
|
script: |
|
|
1094
1191
|
const M = JSON.parse(process.env.PAW_MSG);
|
|
1095
1192
|
const msg = (k, p = {}) => M[k].replace(/\{(\w+)\}/g, (s, n) => (n in p ? p[n] : s));
|
|
1096
1193
|
const row = (name, status, elapsed = '-') => `| ${msg('ios_test_tf.step_' + name)} | ${msg('ios_test_tf.st_' + status)} | ${elapsed} |`;
|
|
1097
|
-
const commentId = parseInt(
|
|
1098
|
-
const startTime = parseInt(
|
|
1099
|
-
const step2EndTime = parseInt(
|
|
1100
|
-
const step1Elapsed =
|
|
1101
|
-
const step2Elapsed =
|
|
1102
|
-
const branchName =
|
|
1103
|
-
const buildNumber =
|
|
1104
|
-
const version =
|
|
1105
|
-
const commitHash =
|
|
1106
|
-
const runId =
|
|
1194
|
+
const commentId = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_COMMENT_ID);
|
|
1195
|
+
const startTime = parseInt(process.env.PAW_IN_NEEDS_NOTIFY_START_OUTPUTS_START_TIME);
|
|
1196
|
+
const step2EndTime = parseInt(process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_END_TIME) || 0;
|
|
1197
|
+
const step1Elapsed = process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP1_ELAPSED;
|
|
1198
|
+
const step2Elapsed = process.env.PAW_IN_NEEDS_BUILD_IOS_TEST_OUTPUTS_STEP2_ELAPSED;
|
|
1199
|
+
const branchName = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BRANCH_NAME;
|
|
1200
|
+
const buildNumber = process.env.PAW_IN_GITHUB_EVENT_CLIENT_PAYLOAD_BUILD_NUMBER;
|
|
1201
|
+
const version = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_VERSION;
|
|
1202
|
+
const commitHash = process.env.PAW_IN_NEEDS_PREPARE_TEST_BUILD_OUTPUTS_COMMIT_HASH;
|
|
1203
|
+
const runId = process.env.PAW_IN_GITHUB_RUN_ID;
|
|
1107
1204
|
const runUrl = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${runId}`;
|
|
1108
1205
|
|
|
1109
1206
|
const now = Date.now();
|