@jx0/jmux 0.1.5 → 0.2.0
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/package.json +1 -1
- package/src/main.ts +13 -4
package/package.json
CHANGED
package/src/main.ts
CHANGED
|
@@ -12,7 +12,7 @@ import { homedir } from "os";
|
|
|
12
12
|
|
|
13
13
|
// --- CLI commands (run and exit before TUI) ---
|
|
14
14
|
|
|
15
|
-
const VERSION = "0.
|
|
15
|
+
const VERSION = "0.2.0";
|
|
16
16
|
|
|
17
17
|
const HELP = `jmux — a persistent session sidebar for tmux
|
|
18
18
|
|
|
@@ -120,10 +120,19 @@ const configFile = resolve(jmuxDir, "config", "tmux.conf");
|
|
|
120
120
|
let sessionName: string | undefined;
|
|
121
121
|
let socketName: string | undefined;
|
|
122
122
|
for (let i = 2; i < process.argv.length; i++) {
|
|
123
|
-
|
|
123
|
+
const arg = process.argv[i];
|
|
124
|
+
if (arg === "--socket" || arg === "-L") {
|
|
124
125
|
socketName = process.argv[++i];
|
|
125
|
-
} else if (
|
|
126
|
-
|
|
126
|
+
} else if (arg.startsWith("-")) {
|
|
127
|
+
console.error(`Unknown option: ${arg}`);
|
|
128
|
+
console.error("Run 'jmux --help' for usage.");
|
|
129
|
+
process.exit(1);
|
|
130
|
+
} else if (!sessionName) {
|
|
131
|
+
sessionName = arg;
|
|
132
|
+
} else {
|
|
133
|
+
console.error(`Unexpected argument: ${arg}`);
|
|
134
|
+
console.error("Run 'jmux --help' for usage.");
|
|
135
|
+
process.exit(1);
|
|
127
136
|
}
|
|
128
137
|
}
|
|
129
138
|
const cols = process.stdout.columns || 80;
|