gowalk-cicd 1.0.201 → 1.0.203

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.
@@ -38,7 +38,6 @@ backend:
38
38
  runtime-env: ${{ secrets.BACKEND_RUNTIME_ENV }}
39
39
  public-base-url: ${{ vars.BACKEND_PUBLIC_BASE_URL }}
40
40
  public-health-url: ${{ vars.BACKEND_PUBLIC_HEALTH_URL }}
41
- expected-build-sha: ${{ vars.BACKEND_PUBLIC_HEALTH_URL && github.sha || '' }}
42
41
  ingress-required: ${{ vars.BACKEND_INGRESS_REQUIRED || 'false' }}
43
42
  ingress-token: ${{ secrets.BACKEND_INGRESS_TOKEN }}
44
43
  workflows:
@@ -52,6 +51,12 @@ until the app explicitly replaces their references in this file. Keep passwords,
52
51
  signing material, tokens and private keys in GitHub Secrets. Reference their names;
53
52
  never put their values in this configuration.
54
53
 
54
+ Leave `backend.expected-build-sha` omitted to inherit the managed operation-aware default:
55
+ network diagnostics uses the explicit `diagnostic-build-sha`, while deployment uses its source SHA.
56
+ Upgrades remove only the former generated setting
57
+ `${{ vars.BACKEND_PUBLIC_HEALTH_URL && github.sha || '' }}`, which otherwise overrides the diagnostic
58
+ input. Custom build expressions remain unchanged; callers must supply the observed deployed SHA.
59
+
55
60
  Backend discovery accepts `compose.yaml`, `compose.yml`, `docker-compose.yaml` and
56
61
  `docker-compose.yml` inside `backend/` or `server/`, or at the repository root with a Dockerfile in
57
62
  exactly one of those source directories. Multiple matches require an explicit selection; no file is
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gowalk-cicd",
3
- "version": "1.0.201",
3
+ "version": "1.0.203",
4
4
  "description": "Zero-config GitHub Actions delivery for iOS TestFlight and Android Google Play.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -1,5 +1,8 @@
1
1
  // Reviewed build-only recipes. Names alone never authorize candidate execution.
2
- const RUBY = 'ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b';
2
+ const RUBY = new Set([
3
+ 'ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b',
4
+ 'ruby/setup-ruby@14594264cd68ce8a2345dd349bc3d138a4ef85c8',
5
+ ]);
3
6
  // The optional grep drops beta and release-candidate Xcodes, whose builds App Store Connect refuses.
4
7
  const XCODE = /^XCODE_PATH=\$\(ls -d \/Applications\/Xcode_\d+\*\.app (?:\| grep -viE 'beta\|release_candidate\|_rc' )?\| sort -V \| tail -1\)\n/;
5
8
  const XCODE_END = 'sudo xcode-select -s "$XCODE_PATH/Contents/Developer"\nxcodebuild -version\nswift --version\n';
@@ -13,9 +16,10 @@ const SDK = /^\s*"\$ANDROID_HOME\/cmdline-tools\/latest\/bin\/sdkmanager" 'platf
13
16
  export function reviewedBuildStep(step) {
14
17
  const allowed = ['name', 'id', 'uses', 'with', 'run', 'if', 'shell'];
15
18
  if (!step || Object.keys(step).some(key => !allowed.includes(key))) return false;
16
- if (step.uses === RUBY && !step.run) {
19
+ if (RUBY.has(step.uses) && !step.run) {
17
20
  return Object.entries(step.with || {}).every(([key, value]) =>
18
- ['ruby-version', 'bundler'].includes(key) && /^\d+(?:\.\d+){0,2}$/.test(String(value)));
21
+ key === 'bundler-cache' ? value === false
22
+ : ['ruby-version', 'bundler'].includes(key) && /^\d+(?:\.\d+){0,2}$/.test(String(value)));
19
23
  }
20
24
  if (step.uses || step.with || step.shell && step.shell !== 'bash' || typeof step.run !== 'string') return false;
21
25
  return XCODE.test(step.run) && step.run.replace(XCODE, '') === XCODE_END
@@ -31,7 +31,14 @@ export function extractSettings(config, file, workflow) {
31
31
  }
32
32
  }
33
33
 
34
- export function applySettings(config, file, workflow) {
34
+ export function applySettings(config, file, workflow, defaults) {
35
+ if (file === 'deploy-backend.yml'
36
+ && config.backend?.['expected-build-sha'] === "${{ vars.BACKEND_PUBLIC_HEALTH_URL && github.sha || '' }}") {
37
+ // Former generated default masks the diagnostic build input after a configured upgrade.
38
+ delete config.backend['expected-build-sha'];
39
+ const path = [...backend, 'expected-build-sha'];
40
+ assign(workflow, { path, value: at(defaults, path) });
41
+ }
35
42
  for (const { name, path } of settingsPaths(file)) {
36
43
  const value = at(config, name);
37
44
  if (value !== undefined) assign(workflow, { path, value });
@@ -67,7 +67,7 @@ function upgradeWorkflow(root, file, templateDir, state) {
67
67
  result = mergeChanges(base.value, current, state.config.workflows[file]?.overrides || [], file);
68
68
  }
69
69
  if (state.migrating) extractSettings(state.config, file, result);
70
- result = applySettings(state.config, file, result);
70
+ result = applySettings(state.config, file, result, current);
71
71
  const options = settingsPaths(file);
72
72
  const overrides = differences(current, result)
73
73
  .filter(change => !options.some(({ path }) => equal(path, change.path)));
Binary file