miinideck 0.1.0 → 0.1.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/index.js +6 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -289,7 +289,12 @@ async function deploy(args) {
|
|
|
289
289
|
// 3. finalize.
|
|
290
290
|
const finalizeBody = { path: storagePath, slug, fileKind, source_filename: sourceFilename };
|
|
291
291
|
if (knownDocId && step1.json.slug === slug) finalizeBody.replace_doc_id = knownDocId;
|
|
292
|
-
|
|
292
|
+
// Default the title to the file/folder name (extension stripped), matching the
|
|
293
|
+
// web upload. Custom name via --name; rename later in the dashboard. (On an
|
|
294
|
+
// update/replace the server keeps the existing title, so a manual rename sticks.)
|
|
295
|
+
finalizeBody.title = args.flags.name
|
|
296
|
+
? String(args.flags.name)
|
|
297
|
+
: sourceFilename.replace(/\.(html?|zip)$/i, "");
|
|
293
298
|
if (args.flags.password) finalizeBody.password = String(args.flags.password);
|
|
294
299
|
if (args.flags.keep) finalizeBody.expiry_preset = "never";
|
|
295
300
|
|
package/package.json
CHANGED