[object Object]

← back to Gmc Titlefix

weight-override: DEFAULT_DS so --apply needs no long arg (terminal-wrap-safe) + short ~/gw.sh wrapper

93e51cb4f0b7331e2e9d08c8e6ec6cab36f87c3e · 2026-07-09 09:16:51 -0700 · steve

Files touched

Diff

commit 93e51cb4f0b7331e2e9d08c8e6ec6cab36f87c3e
Author: steve <steve@designerwallcoverings.com>
Date:   Thu Jul 9 09:16:51 2026 -0700

    weight-override: DEFAULT_DS so --apply needs no long arg (terminal-wrap-safe) + short ~/gw.sh wrapper
---
 gmc-weight-override.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gmc-weight-override.js b/gmc-weight-override.js
index 80528e5..7556bbe 100644
--- a/gmc-weight-override.js
+++ b/gmc-weight-override.js
@@ -24,7 +24,10 @@ const INCLUDE_SAMPLES = args.includes('--include-samples');
 const SAMPLES_ONLY = args.includes('--samples-only');  // Steve: rolls are already correct — fix ONLY samples @ 0.35lb
 const CREATE_DS = args.includes('--create-ds');
 const APPLY = args.includes('--apply');
-const DS = APPLY ? args[args.indexOf('--apply') + 1] : null;
+// Default to the already-linked weight datasource so no long arg is needed (terminal-wrap-safe).
+const DEFAULT_DS = 'accounts/146735262/dataSources/10683334493';
+const _dsArg = APPLY ? args[args.indexOf('--apply') + 1] : null;
+const DS = APPLY ? ((_dsArg && !_dsArg.startsWith('--')) ? _dsArg : DEFAULT_DS) : null;
 const LIST_DS = args.includes('--list-ds');
 const VERIFY_LINK = args.includes('--verify-link');
 const VL_DS = VERIFY_LINK ? args[args.indexOf('--verify-link') + 1] : null;

← 327c4ba add --samples-only mode: fix ONLY $4.25 samples @ 0.35lb, le  ·  back to Gmc Titlefix  ·  auto-save: 2026-07-17T19:47:29 (1 files) — gmc-dwla-peryard- 2abd4af →