@siddhaartha_bs/monkcli 0.1.1 → 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.
package/README.md CHANGED
@@ -16,6 +16,22 @@ npm install -g @siddhaartha_bs/monkcli
16
16
  monkcli
17
17
  ```
18
18
 
19
+ If your npm global install tries to write to a system directory and asks for `sudo`,
20
+ prefer a user-local npm prefix instead of installing with elevated privileges:
21
+
22
+ ```bash
23
+ mkdir -p "$HOME/.local"
24
+ npm config set prefix "$HOME/.local"
25
+ echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
26
+ source ~/.zshrc
27
+ ```
28
+
29
+ Then install again:
30
+
31
+ ```bash
32
+ npm install -g @siddhaartha_bs/monkcli
33
+ ```
34
+
19
35
  ### npx
20
36
 
21
37
  ```bash
@@ -28,6 +44,22 @@ npx @siddhaartha_bs/monkcli
28
44
  npm install -g @siddhaartha_bs/monkcli@latest
29
45
  ```
30
46
 
47
+ `@latest` means the latest version published to npm, not the latest local commits on `main`.
48
+
49
+ ## Check Version
50
+
51
+ Check the installed CLI version:
52
+
53
+ ```bash
54
+ monkcli --version
55
+ ```
56
+
57
+ Check the latest published npm version:
58
+
59
+ ```bash
60
+ npm view @siddhaartha_bs/monkcli version
61
+ ```
62
+
31
63
  ## Uninstall
32
64
 
33
65
  ```bash
package/dist/monkcli.js CHANGED
@@ -1127,7 +1127,7 @@ function MenuControls() {
1127
1127
  " change value | ",
1128
1128
  /* @__PURE__ */ jsx2(KeyTag, { label: "Enter", tone: "success" }),
1129
1129
  " start | ",
1130
- /* @__PURE__ */ jsx2(KeyTag, { label: "q", tone: "danger" }),
1130
+ /* @__PURE__ */ jsx2(KeyTag, { label: "Ctrl+C", tone: "danger" }),
1131
1131
  " quit"
1132
1132
  ] });
1133
1133
  }
@@ -1137,7 +1137,7 @@ function RunningControls() {
1137
1137
  " new test | ",
1138
1138
  /* @__PURE__ */ jsx2(KeyTag, { label: "Enter", tone: "success" }),
1139
1139
  " menu | ",
1140
- /* @__PURE__ */ jsx2(KeyTag, { label: "q", tone: "danger" }),
1140
+ /* @__PURE__ */ jsx2(KeyTag, { label: "Ctrl+C", tone: "danger" }),
1141
1141
  " quit"
1142
1142
  ] });
1143
1143
  }
@@ -1156,7 +1156,7 @@ function ErrorScreen(props) {
1156
1156
  /* @__PURE__ */ jsxs2(Text2, { children: [
1157
1157
  /* @__PURE__ */ jsx2(KeyTag, { label: "Enter", tone: "success" }),
1158
1158
  " menu | ",
1159
- /* @__PURE__ */ jsx2(KeyTag, { label: "q", tone: "danger" }),
1159
+ /* @__PURE__ */ jsx2(KeyTag, { label: "Ctrl+C", tone: "danger" }),
1160
1160
  " quit"
1161
1161
  ] })
1162
1162
  ] });
@@ -1322,7 +1322,7 @@ function App() {
1322
1322
  const panelWidth = Math.max(36, Math.min(safeWidth - 2, 120));
1323
1323
  const renderCentered = (content) => /* @__PURE__ */ jsx3(Box3, { width: safeWidth, height: safeHeight, justifyContent: "center", alignItems: "center", children: /* @__PURE__ */ jsx3(Box3, { width: panelWidth, flexDirection: "column", children: content }) });
1324
1324
  useInput((input, key) => {
1325
- if (key.ctrl && input === "c" || input === "q") {
1325
+ if (key.ctrl && input === "c") {
1326
1326
  exit();
1327
1327
  return;
1328
1328
  }
@@ -1448,4 +1448,11 @@ function App() {
1448
1448
 
1449
1449
  // apps/cli/src/index.tsx
1450
1450
  import { jsx as jsx4 } from "react/jsx-runtime";
1451
- render(/* @__PURE__ */ jsx4(App, {}));
1451
+ if (process.stdout.isTTY) {
1452
+ process.stdout.write("\x1B[?1049h");
1453
+ }
1454
+ var instance = render(/* @__PURE__ */ jsx4(App, {}));
1455
+ await instance.waitUntilExit();
1456
+ if (process.stdout.isTTY) {
1457
+ process.stdout.write("\x1B[?1049l");
1458
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@siddhaartha_bs/monkcli",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "CLI typing test inspired by Monkeytype.",
5
5
  "type": "module",
6
6
  "engines": {
@@ -23,14 +23,18 @@
23
23
  "react": "^19.2.4"
24
24
  },
25
25
  "scripts": {
26
+ "changeset": "changeset",
26
27
  "dev": "tsx --tsconfig ./apps/cli/tsconfig.json ./apps/cli/src/index.tsx",
27
28
  "build": "node ./scripts/build-package.mjs",
28
29
  "prepack": "npm run build",
30
+ "version-packages": "changeset version && npm install --package-lock-only --ignore-scripts",
31
+ "release": "npm run build && changeset publish",
29
32
  "test": "vitest",
30
33
  "docker:build": "docker build -t monkcli:local .",
31
34
  "docker:run": "docker run --rm -it monkcli:local"
32
35
  },
33
36
  "devDependencies": {
37
+ "@changesets/cli": "^2.30.0",
34
38
  "@types/node": "^25.3.3",
35
39
  "@types/react": "^19.2.14",
36
40
  "esbuild": "^0.25.9",