@mundy/agrep 0.1.0 → 0.1.1

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 (3) hide show
  1. package/README.md +5 -2
  2. package/bin.js +11 -3
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -10,10 +10,13 @@ and the shim runs it through [uv](https://docs.astral.sh/uv/) (or pipx). uv mana
10
10
  python itself, so this works even on a machine with no python installed.
11
11
 
12
12
  ```
13
- npm i -g agrep-cli
13
+ npm i -g @mundy/agrep
14
+ # or: npm i -g agrep-cli
14
15
  agrep "race condition" # first run indexes your agent stores, then greps
15
16
  ```
16
17
 
17
- Prefer the direct route? `uv tool install agrep` same thing, no node in the middle.
18
+ The npm shim pins the matching PyPI version under the hood, so npm and PyPI releases
19
+ do not drift. Prefer the direct route? `uv tool install agrep==0.1.1` — same thing,
20
+ no node in the middle.
18
21
 
19
22
  Full docs: https://github.com/dannyisbad/agrep
package/bin.js CHANGED
@@ -8,8 +8,9 @@
8
8
 
9
9
  "use strict";
10
10
  const { spawnSync } = require("child_process");
11
+ const { version } = require("./package.json");
11
12
 
12
- const SPEC = process.env.AGREP_PYPI_SPEC || "agrep";
13
+ const SPEC = process.env.AGREP_PYPI_SPEC || `agrep==${version}`;
13
14
  const args = process.argv.slice(2);
14
15
 
15
16
  function has(cmd) {
@@ -28,7 +29,13 @@ function run(cmd, cmdArgs) {
28
29
 
29
30
  if (has("uv")) {
30
31
  // `uvx agrep` == `uv tool run agrep`; --from lets AGREP_PYPI_SPEC point anywhere
31
- run("uv", ["tool", "run", "--from", SPEC, "agrep", ...args]);
32
+ run("uv", [
33
+ "tool", "run",
34
+ "--exclude-newer-package", "agrep=false",
35
+ "--from", SPEC,
36
+ "agrep",
37
+ ...args,
38
+ ]);
32
39
  } else if (has("pipx")) {
33
40
  run("pipx", ["run", "--spec", SPEC, "agrep", ...args]);
34
41
  } else {
@@ -38,7 +45,8 @@ if (has("uv")) {
38
45
  (process.platform === "win32"
39
46
  ? ' powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"'
40
47
  : " curl -LsSf https://astral.sh/uv/install.sh | sh") +
41
- "\n\nthen `agrep` works. (or skip npm entirely: `uv tool install agrep`)"
48
+ `\n\nthen \`agrep\` works. This npm package runs PyPI agrep==${version}; ` +
49
+ `you can also install that directly with \`uv tool install agrep==${version}\`.`
42
50
  );
43
51
  process.exit(1);
44
52
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mundy/agrep",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "grep your AI coding agents' chat history (Claude Code, Codex, opencode, Antigravity, Kimi, Cline) — npm shim that runs the real package via uv/pipx",
5
5
  "bin": { "agrep": "bin.js" },
6
6
  "files": ["bin.js", "README.md"],