@jarkkojs/readseek 0.4.2 → 0.4.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/README.md +77 -8
  2. package/package.json +4 -4
package/README.md CHANGED
@@ -1,15 +1,84 @@
1
1
  # readseek
2
2
 
3
- - `readseek` is a structural source reader with stable line hashes.
4
- - `readseek` is inspired by and based on the ideas of
5
- [`pi-hashline-readmap`](https://github.com/coctostan/pi-hashline-readmap).
6
- - `man man/man1/readseek.1` provides further information on its usage.
3
+ `readseek` is a structural source reader for scripts, editors, and coding agents.
4
+ It emits pretty-printed JSON with stable `LINE:HASH` anchors, structural symbol
5
+ maps, parse diagnostics, AST search matches, references, and rename plans.
7
6
 
8
- Pass `--help` to any command for details.
7
+ Current documented CLI API: **0.4.x**.
8
+
9
+ ## Install
10
+
11
+ ```sh
12
+ npm install -g @jarkkojs/readseek
13
+ ```
14
+
15
+ Or build the native binary from source:
16
+
17
+ ```sh
18
+ cargo build --release
19
+ ```
20
+
21
+ ## Common commands
22
+
23
+ ```sh
24
+ readseek detect src/main.rs
25
+ readseek read src/main.rs --start 10 --end 20
26
+ readseek map src/main.rs
27
+ readseek check src/main.rs
28
+ readseek symbol src/main.rs --name run
29
+ readseek identify src/main.rs:42 --column 8
30
+ readseek def src run --language rust --format plain
31
+ readseek refs src main --language rust --format plain
32
+ readseek search src 'fn $NAME() { $$$BODY }' --language rust
33
+ readseek rename src/main.rs --line 42 --column 8 --to renamed
34
+ ```
35
+
36
+ Use `--stdin <path>` with `detect`, `read`, `map`, `check`, `symbol`, and
37
+ `identify` to analyze unsaved editor buffers while still providing a path for
38
+ language detection:
39
+
40
+ ```sh
41
+ printf '%s\n' 'fn main() {}' | readseek identify --stdin scratch.rs --line 1 --column 4
42
+ ```
43
+
44
+ Use `def --from-identify` to pipe `identify` JSON into definition lookup:
45
+
46
+ ```sh
47
+ readseek identify src/main.rs:42 --column 8 | readseek def --from-identify src --format plain
48
+ ```
49
+
50
+ ## 0.4 CLI notes
51
+
52
+ - `read --start` is the range-start option. The old `--offset` spelling is not
53
+ part of the 0.4 API.
54
+ - `def --from-identify` reads `identify` JSON from standard input. The old
55
+ `def --stdin` spelling is not part of the 0.4 API.
56
+ - Cursor columns are one-based byte columns. `identify`, `refs --scope`, and
57
+ `rename` reject line/column values outside the selected line instead of
58
+ silently clamping them.
59
+ - `--readseek-dir <dir>` pins the `.readseek` cache directory and must appear
60
+ before the subcommand.
61
+
62
+ ## Cache
63
+
64
+ `readseek init [path]` creates a `.readseek/` directory containing map cache files
65
+ under `maps/` and definition-index shards under `def-index/`. Commands discover
66
+ that directory by walking up from the target path, or use the directory passed by
67
+ `--readseek-dir`.
68
+
69
+ ## Documentation
70
+
71
+ The manual page is the authoritative CLI reference:
72
+
73
+ ```sh
74
+ man man/man1/readseek.1
75
+ ```
76
+
77
+ Pass `--help` to any command for command-specific usage.
9
78
 
10
79
  ## Licensing
11
80
 
12
81
  The JavaScript npm wrapper is licensed under `Apache-2.0`. The Rust source and
13
- native binaries are licensed under `LGPL-2.1-or-later`. Corresponding source
14
- for each published native binary is available from the GitHub repository tag
15
- that matches the package version.
82
+ native binaries are licensed under `LGPL-2.1-or-later`. Corresponding source for
83
+ each published native binary is available from the GitHub repository tag that
84
+ matches the package version.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jarkkojs/readseek",
3
- "version": "0.4.2",
3
+ "version": "0.4.3",
4
4
  "description": "A structural read command",
5
5
  "license": "Apache-2.0 AND LGPL-2.1-or-later",
6
6
  "homepage": "https://github.com/jarkkojs/readseek#readme",
@@ -21,9 +21,9 @@
21
21
  "LICENSE-LGPL-2.1"
22
22
  ],
23
23
  "optionalDependencies": {
24
- "@jarkkojs/readseek-darwin-arm64": "0.4.2",
25
- "@jarkkojs/readseek-linux-x64": "0.4.2",
26
- "@jarkkojs/readseek-win32-x64": "0.4.2"
24
+ "@jarkkojs/readseek-darwin-arm64": "0.4.3",
25
+ "@jarkkojs/readseek-linux-x64": "0.4.3",
26
+ "@jarkkojs/readseek-win32-x64": "0.4.3"
27
27
  },
28
28
  "publishConfig": {
29
29
  "access": "public"