@sprid/release 1.6.1 → 1.6.3

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 CHANGED
@@ -3,6 +3,14 @@
3
3
  @sprid/release follows semver: a breaking change to a command's arguments, its
4
4
  output shape or its exit codes is a major release.
5
5
 
6
+ ## 1.6.3 - 2026-11-24
7
+
8
+ - App Store Connect metadata pushes update the promotional text on the live version when no editable version exists, instead of skipping it.
9
+
10
+ ## 1.6.2 - 2026-11-19
11
+
12
+ - Google Play listing updates retry without submitting for review when Play requires it. The CLI tells you to submit the saved changes from Publishing overview in Play Console.
13
+
6
14
  ## 1.6.1 - 2026-11-13
7
15
 
8
16
  - `retention` fails locally on a message body over 144 characters, which App Store
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sprid/release",
3
- "version": "1.6.1",
3
+ "version": "1.6.3",
4
4
  "description": "Build, sign and release mobile apps locally. Store copy, screenshots, binary uploads and review submissions from one app-owned configuration. Dry run by default.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "type": "module",
@@ -81,7 +81,24 @@ export async function pushAscMetadata({ config, copy, localeMap, execute = false
81
81
  EDITABLE_STATES.has(v.attributes.appStoreState ?? v.attributes.appVersionState),
82
82
  );
83
83
  if (!editableVersion) {
84
- console.log(' ⚠ No editable version — skipping description/keywords/promo. Create a version in ASC first.');
84
+ // Apple lets the promotional text change on the version that is live, with no
85
+ // new version or review; the description and keywords wait for an editable one.
86
+ const live = versions.data.find((v: any) => (v.attributes.appStoreState ?? v.attributes.appVersionState) === 'READY_FOR_SALE');
87
+ console.log(' ⚠ No editable version — skipping description/keywords. Create a version in ASC first.');
88
+ if (live) {
89
+ console.log(` ✓ Live version: ${live.attributes.versionString} (id=${live.id}), promotional text only`);
90
+ const liveLocs = await client.api(`/appStoreVersions/${live.id}/appStoreVersionLocalizations`);
91
+ for (const [locale, c] of locales) {
92
+ const existing = liveLocs.data.find((l: any) => l.attributes.locale === locale);
93
+ if (!existing || !c.promotionalText || existing.attributes.promotionalText === c.promotionalText) continue;
94
+ console.log(` [${locale}] PATCH promotionalText`);
95
+ if (!execute) continue;
96
+ await client.api(`/appStoreVersionLocalizations/${existing.id}`, {
97
+ method: 'PATCH',
98
+ body: JSON.stringify({ data: { type: 'appStoreVersionLocalizations', id: existing.id, attributes: { promotionalText: c.promotionalText } } }),
99
+ });
100
+ }
101
+ }
85
102
  } else {
86
103
  console.log(` ✓ Editable version: ${editableVersion.attributes.versionString} (id=${editableVersion.id})`);
87
104
  const vLocs = await client.api(`/appStoreVersions/${editableVersion.id}/appStoreVersionLocalizations`);
@@ -29,8 +29,17 @@ export function createPlayClient(config: AppReleaseConfig): PlayClient {
29
29
 
30
30
  // Retain the exported method name for existing callers. Listing updates never
31
31
  // modify release tracks, even when Play refuses a commit for a draft app.
32
+ // Play refuses an automatic send for review while the app has rejected or
33
+ // pending changes; the edit then commits only with changesNotSentForReview and
34
+ // is sent for review from the Publishing overview in Play Console.
32
35
  async function commitWithDraftStaging(editId: string, _reapply?: (editId: string) => Promise<void>): Promise<void> {
33
- await play.edits.commit({ packageName, editId });
36
+ try {
37
+ await play.edits.commit({ packageName, editId });
38
+ } catch (e: any) {
39
+ if (!String(e?.message ?? '').includes('changesNotSentForReview')) throw e;
40
+ await play.edits.commit({ packageName, editId, changesNotSentForReview: true });
41
+ console.log(' Committed without sending for review. Send the changes from Publishing overview in Play Console.');
42
+ }
34
43
  }
35
44
 
36
45
  async function withEdit<T>(fn: (editId: string) => Promise<T>): Promise<T> {