contextswitch 0.1.2 → 0.1.3

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.
Files changed (2) hide show
  1. package/dist/cli.js +5 -3
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -11,15 +11,17 @@ import "./chunk-PNKVD2UK.js";
11
11
  import { Command } from "commander";
12
12
  import picocolors from "picocolors";
13
13
  import { existsSync, readFileSync, unlinkSync } from "fs";
14
- import { join } from "path";
14
+ import { join, dirname } from "path";
15
+ import { fileURLToPath } from "url";
15
16
  var pc = picocolors;
16
17
  function getVersion() {
17
18
  try {
18
- const packagePath = join(__dirname, "..", "package.json");
19
+ const currentDir = typeof __dirname !== "undefined" ? __dirname : dirname(fileURLToPath(import.meta.url));
20
+ const packagePath = join(currentDir, "..", "package.json");
19
21
  const packageJson = JSON.parse(readFileSync(packagePath, "utf-8"));
20
22
  return packageJson.version;
21
23
  } catch {
22
- return "0.1.0";
24
+ return "0.1.3";
23
25
  }
24
26
  }
25
27
  function processSessionFallbackMarker() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "contextswitch",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "Domain-based context management for Claude Code CLI",
5
5
  "main": "dist/cli.js",
6
6
  "type": "module",