@makefully/adaptfully 3.12.0 → 3.12.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/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project are documented in this file.
|
|
4
4
|
|
|
5
|
+
## 3.12.1 — 2026-07-23
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- **Publish path prompts** — strip wrapping quotes from user-supplied paths (e.g. pasted `"D:\…\key.json"`) so absolute paths are not treated as project-relative.
|
|
10
|
+
|
|
5
11
|
## 3.12.0 — 2026-07-23
|
|
6
12
|
|
|
7
13
|
### Added
|
|
@@ -7,6 +7,7 @@ import {
|
|
|
7
7
|
ensureDeploymentManifest,
|
|
8
8
|
ensurePublishCredentialsGitignore,
|
|
9
9
|
parsePublishCredentialArgv,
|
|
10
|
+
resolveUserPath,
|
|
10
11
|
} from './publish-credentials.js';
|
|
11
12
|
|
|
12
13
|
/**
|
|
@@ -82,7 +83,7 @@ export async function runApplePublish(options = {}) {
|
|
|
82
83
|
let appleJson;
|
|
83
84
|
|
|
84
85
|
if (options.from) {
|
|
85
|
-
const fromPath =
|
|
86
|
+
const fromPath = resolveUserPath(options.from);
|
|
86
87
|
let raw;
|
|
87
88
|
|
|
88
89
|
try {
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
ensurePublishCredentialsGitignore,
|
|
7
7
|
parsePublishCredentialArgv,
|
|
8
8
|
promptRequired,
|
|
9
|
+
resolveUserPath,
|
|
9
10
|
} from './publish-credentials.js';
|
|
10
11
|
|
|
11
12
|
const GOOGLE_REQUIRED_FIELDS = [
|
|
@@ -72,7 +73,7 @@ export async function runGooglePublish(options = {}) {
|
|
|
72
73
|
options.output ?? defaultGooglePublishPath(projectRoot, deploymentKey),
|
|
73
74
|
);
|
|
74
75
|
|
|
75
|
-
const fromPath =
|
|
76
|
+
const fromPath = resolveUserPath(
|
|
76
77
|
await promptRequired(
|
|
77
78
|
'Path to Google Play service account JSON: ',
|
|
78
79
|
options.from ?? process.env.GOOGLE_APPLICATION_CREDENTIALS,
|
package/lib/node/index.js
CHANGED
|
@@ -54,9 +54,11 @@ export {
|
|
|
54
54
|
defaultDeploymentCredentialPath,
|
|
55
55
|
ensureDeploymentManifest,
|
|
56
56
|
ensurePublishCredentialsGitignore,
|
|
57
|
+
normalizeUserPath,
|
|
57
58
|
parsePublishCredentialArgv,
|
|
58
59
|
promptRequired,
|
|
59
60
|
PUBLISH_CREDENTIAL_GITIGNORE_PATTERNS,
|
|
61
|
+
resolveUserPath,
|
|
60
62
|
} from './publish-credentials.js';
|
|
61
63
|
export {
|
|
62
64
|
buildSteamPublishJson,
|
|
@@ -158,6 +158,35 @@ export async function ensureDeploymentManifest(deploymentDir, type, log = consol
|
|
|
158
158
|
return { manifestPath, created: false, updated: true };
|
|
159
159
|
}
|
|
160
160
|
|
|
161
|
+
/**
|
|
162
|
+
* Strip wrapping quotes and whitespace from a user-supplied filesystem path.
|
|
163
|
+
* Quoted absolute paths (common when pasting on Windows) must not be treated as relative.
|
|
164
|
+
*
|
|
165
|
+
* @param {string} value
|
|
166
|
+
* @returns {string}
|
|
167
|
+
*/
|
|
168
|
+
export function normalizeUserPath(value) {
|
|
169
|
+
let result = String(value).trim();
|
|
170
|
+
|
|
171
|
+
if (
|
|
172
|
+
(result.startsWith('"') && result.endsWith('"'))
|
|
173
|
+
|| (result.startsWith("'") && result.endsWith("'"))
|
|
174
|
+
) {
|
|
175
|
+
result = result.slice(1, -1).trim();
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
return result;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* @param {string} value
|
|
183
|
+
* @param {string} [base]
|
|
184
|
+
* @returns {string}
|
|
185
|
+
*/
|
|
186
|
+
export function resolveUserPath(value, base = process.cwd()) {
|
|
187
|
+
return path.resolve(base, normalizeUserPath(value));
|
|
188
|
+
}
|
|
189
|
+
|
|
161
190
|
/**
|
|
162
191
|
* @param {string} prompt
|
|
163
192
|
* @param {string} [existing]
|
|
@@ -165,13 +194,13 @@ export async function ensureDeploymentManifest(deploymentDir, type, log = consol
|
|
|
165
194
|
*/
|
|
166
195
|
export async function promptRequired(prompt, existing) {
|
|
167
196
|
if (existing != null && String(existing).trim() !== '') {
|
|
168
|
-
return
|
|
197
|
+
return normalizeUserPath(existing);
|
|
169
198
|
}
|
|
170
199
|
|
|
171
200
|
const rl = readline.createInterface({ input, output });
|
|
172
201
|
|
|
173
202
|
try {
|
|
174
|
-
const value =
|
|
203
|
+
const value = normalizeUserPath(await rl.question(prompt));
|
|
175
204
|
if (!value) {
|
|
176
205
|
throw new Error(`${prompt.replace(/:\s*$/, '')} is required.`);
|
|
177
206
|
}
|
|
@@ -196,15 +225,15 @@ export function parsePublishCredentialArgv(argv, startIndex = 3) {
|
|
|
196
225
|
const arg = argv[i];
|
|
197
226
|
|
|
198
227
|
if (arg === '--from' && argv[i + 1]) {
|
|
199
|
-
options.from = argv[++i];
|
|
228
|
+
options.from = normalizeUserPath(argv[++i]);
|
|
200
229
|
} else if (arg === '--output' && argv[i + 1]) {
|
|
201
|
-
options.output = argv[++i];
|
|
230
|
+
options.output = normalizeUserPath(argv[++i]);
|
|
202
231
|
} else if (arg === '--deployment' && argv[i + 1]) {
|
|
203
232
|
options.deployment = argv[++i];
|
|
204
233
|
} else if (arg === '--project-root' && argv[i + 1]) {
|
|
205
|
-
options.projectRoot = argv[++i];
|
|
234
|
+
options.projectRoot = normalizeUserPath(argv[++i]);
|
|
206
235
|
} else if (arg === '--steamcmd-dir' && argv[i + 1]) {
|
|
207
|
-
options.steamcmdDir = argv[++i];
|
|
236
|
+
options.steamcmdDir = normalizeUserPath(argv[++i]);
|
|
208
237
|
} else if (arg === '--category' && argv[i + 1]) {
|
|
209
238
|
options.category = argv[++i];
|
|
210
239
|
} else if (arg === '--identity' && argv[i + 1]) {
|