From 80414a785b3eb631b66be747ceefa2c3f8df31bd Mon Sep 17 00:00:00 2001 From: Joshua Shanks Date: Mon, 19 Jan 2026 12:45:33 -0800 Subject: [PATCH] fix: validate empty --config-dir value (#177) Reject --config-dir= with empty value with a clear error message instead of silently failing. Helps users catch typos. --- bin/install.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/bin/install.js b/bin/install.js index 7080db49b..d14c1f8de 100755 --- a/bin/install.js +++ b/bin/install.js @@ -48,7 +48,12 @@ function parseConfigDirArg() { // Also handle --config-dir=value format const configDirArg = args.find(arg => arg.startsWith('--config-dir=') || arg.startsWith('-c=')); if (configDirArg) { - return configDirArg.split('=')[1]; + const value = configDirArg.split('=')[1]; + if (!value) { + console.error(` ${yellow}--config-dir requires a non-empty path${reset}`); + process.exit(1); + } + return value; } return null; }