peekme 0.3.2 → 0.3.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/CHANGELOG.md CHANGED
@@ -1,5 +1,22 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.3 (2026-09-29)
4
+
5
+ - Claude Code with Amazon Bedrock, Google Vertex or an API gateway: explanations failed with
6
+ "Could not load AWS credentials" or "Not logged in", although Claude Code itself worked. The
7
+ explainer did not read your Claude Code settings, so it missed the `env` block, `awsAuthRefresh`,
8
+ `awsCredentialExport`, `gcpAuthRefresh` and `apiKeyHelper` there. It also dropped every
9
+ `CLAUDE_CODE_*` variable, `CLAUDE_CODE_USE_BEDROCK` included. Now it uses the same login and
10
+ provider as `claude` in that directory. Hooks, plugins and MCP servers from your settings still
11
+ do not run for explanations.
12
+ - Claude Code's classic screen: when `claude` started lower on the screen, under earlier shell
13
+ output, the box could land a few rows off and repeat lines from above it. peekme now asks the
14
+ terminal where the cursor is when it starts, and the box never covers the shell lines above
15
+ the agent.
16
+ - Agents are listed as Claude Code, Codex, Copilot CLI everywhere. Plain `peekme` now runs the
17
+ first one of them that is installed, in that order. Before, it preferred Codex.
18
+ - A shell setup from an older version that differs only in this order is left as it is.
19
+
3
20
  ## 0.3.2 (2026-09-28)
4
21
 
5
22
  - Updating peekme now also updates your shell setup. Before, a setup made with an older version
package/README.md CHANGED
@@ -1,23 +1,40 @@
1
1
  # peekme
2
2
 
3
- Peek me. Pick me. Select text in [Codex CLI](https://github.com/openai/codex),
4
- [Claude Code](https://github.com/anthropics/claude-code) or
3
+ Pick me. Select text in [Claude Code](https://github.com/anthropics/claude-code),
4
+ [Codex CLI](https://github.com/openai/codex) or
5
5
  [GitHub Copilot CLI](https://github.com/github/copilot-cli) output, press **Alt+P** (**Option+P** on a Mac), and a short
6
6
  explanation opens right next to that text, inside the terminal. The other lines move to make
7
7
  room, like Peek in VS Code. Esc closes it and the screen is exactly as before.
8
8
 
9
- ![peekme demo: type codex, ask a question, select "noisy commits" in the answer, press Alt+P, read the explanation, press Esc](https://raw.githubusercontent.com/GregoryBolshakov/peekme/main/docs/demo.gif)
9
+ ![peekme in Claude Code: ask about detached HEAD, select "git switch -" in the answer, press Alt+P, read the explanation, press Esc](https://raw.githubusercontent.com/GregoryBolshakov/peekme/main/docs/demo-claude.gif)
10
10
 
11
11
  The explanation comes from a small, fast model and it knows the conversation. If you select
12
12
  "its split panes" in an answer that recommends Kitty, it tells you it is about Kitty.
13
13
 
14
- Status: 0.3.2. Tested with Codex 0.157, Claude Code 2.1.283 and Copilot CLI 1.0.89 on Linux, also
14
+ Status: 0.3.3. Tested with Claude Code 2.1.284, Codex 0.159 and Copilot CLI 1.0.89 on Linux, also
15
15
  inside tmux and over SSH. On macOS it is tested in Terminal and iTerm2 with a stand-in agent, also
16
16
  inside tmux and over SSH.
17
17
 
18
+ ## One peekme for all your agents
19
+
20
+ Many developers have more than one agent CLI and switch between them during the day. peekme
21
+ works the same way in each of them. You install it once, and the key and the box are the same
22
+ everywhere. Claude Code, Codex CLI
23
+ and GitHub Copilot CLI work today, and more agents are planned. If one agent gets its own way to
24
+ explain a selection some day, it will work in that agent only. peekme keeps working in all of
25
+ them.
26
+
27
+ Codex CLI:
28
+
29
+ ![peekme in Codex CLI: select "noisy commits" in the answer, press Alt+P, read the explanation, press Esc](https://raw.githubusercontent.com/GregoryBolshakov/peekme/main/docs/demo.gif)
30
+
31
+ GitHub Copilot CLI:
32
+
33
+ ![peekme in GitHub Copilot CLI: ask about set -euo pipefail, select "pipefail" in the answer, press Alt+P, read the explanation, press Esc](https://raw.githubusercontent.com/GregoryBolshakov/peekme/main/docs/demo-copilot.gif)
34
+
18
35
  ## Install
19
36
 
20
- You need Codex CLI, Claude Code or GitHub Copilot CLI (logged in). More than one is fine too. Then install peekme in one of
37
+ You need Claude Code, Codex CLI or GitHub Copilot CLI (logged in). More than one is fine too. Then install peekme in one of
21
38
  these ways and run `peekme install`:
22
39
 
23
40
  ```
@@ -40,7 +57,7 @@ curl --proto '=https' --tlsv1.2 -LsSf https://github.com/GregoryBolshakov/peekme
40
57
 
41
58
  Ready binaries are there too, for Linux and macOS on x86_64 and ARM.
42
59
 
43
- After this, `codex`, `claude` and `copilot` open with peekme in every new terminal. You keep
60
+ After this, `claude`, `codex` and `copilot` open with peekme in every new terminal. You keep
44
61
  typing them as always, and your aliases and scripts that call them keep working. `peekme install`
45
62
  adds a short, marked block to your `~/.bashrc` or `~/.zshrc` (for fish, a file in
46
63
  `~/.config/fish/conf.d`). If you install one of the agents later, it gets peekme too.
@@ -48,8 +65,8 @@ adds a short, marked block to your `~/.bashrc` or `~/.zshrc` (for fish, a file i
48
65
  ```
49
66
  peekme doctor # check the setup, and see what is in the way if something is
50
67
  peekme uninstall # remove the block, your files are as before
51
- command codex # run plain Codex once
52
68
  command claude # run plain Claude Code once
69
+ command codex # run plain Codex once
53
70
  command copilot # run plain Copilot CLI once
54
71
  ```
55
72
 
@@ -60,9 +77,9 @@ itself the next time it starts, and says so once. They work in new terminals.
60
77
 
61
78
  ## Use
62
79
 
63
- Start Codex, Claude Code or Copilot CLI as always. Select text with the mouse as you normally
64
- do, then press Alt+P. When the agent draws full screen (Codex since 0.157, Copilot CLI, Claude
65
- Code with `"tui": "fullscreen"`), it makes the selection itself, and peekme uses that selection.
80
+ Start Claude Code, Codex or Copilot CLI as always. Select text with the mouse as you normally
81
+ do, then press Alt+P. When the agent draws full screen (Claude Code with `"tui": "fullscreen"`,
82
+ Codex since 0.157, Copilot CLI), it makes the selection itself, and peekme uses that selection.
66
83
 
67
84
  | Key | When | What it does |
68
85
  |---|---|---|
@@ -83,20 +100,20 @@ you type Greek, `π` stays a letter. If your terminal sends Option as Meta, Opti
83
100
  When the agent draws full screen, peekme gets the selection from the agent. Otherwise (Claude
84
101
  Code's classic screen) it reads the clipboard: iTerm2 copies a selection there by itself, in
85
102
  Terminal press Cmd+C after you select. Over SSH only the agent's own selection can be read, so
86
- use the full screen mode there (Codex and Copilot CLI use it by default, Claude Code with
87
- `"tui": "fullscreen"`).
103
+ use the full screen mode there (Claude Code with `"tui": "fullscreen"`, Codex and Copilot CLI
104
+ by default).
88
105
 
89
106
  In Claude Code, Alt+P opens the model picker. With peekme it explains the selection instead.
90
107
  `/model` still opens the model picker.
91
108
 
92
109
  No API key is needed. peekme asks the agent's own CLI, with your existing login:
93
110
 
94
- - Codex: its `app-server`, on a temporary thread that is not saved. Since Codex 0.157 a shared
95
- Codex server runs in the background, and peekme uses it, so it adds only a few MB of memory.
96
- Without that server it starts its own `codex app-server`, which takes about 250 MB.
97
111
  - Claude Code: `claude -p` on Haiku, without tools and without saving the session, so nothing
98
112
  appears in `/resume`. After the first explanation one `claude -p` waits in the background for
99
113
  the next one, so it starts in about half a second. It takes about 210 MB.
114
+ - Codex: its `app-server`, on a temporary thread that is not saved. Since Codex 0.157 a shared
115
+ Codex server runs in the background, and peekme uses it, so it adds only a few MB of memory.
116
+ Without that server it starts its own `codex app-server`, which takes about 250 MB.
100
117
  - Copilot CLI: its headless server (`copilot --headless`, the one the Copilot SDK uses), started
101
118
  on the first explanation. Each explanation is a short session without tools, and peekme
102
119
  deletes it afterwards, so nothing appears in your session list. The model is Copilot's Auto
@@ -104,9 +121,9 @@ No API key is needed. peekme asks the agent's own CLI, with your existing login:
104
121
 
105
122
  It does use your plan, a little for each explanation. Nothing starts before the first Alt+P.
106
123
 
107
- Only the interactive screen gets peekme: `codex`, `codex "prompt"`, `codex resume`,
108
- `codex fork`, `claude`, `claude "prompt"`, `claude --resume`, `claude -c`, and `copilot`,
109
- `copilot -i "prompt"`, `copilot --resume`. Commands like `codex exec`, `claude -p`, `copilot -p`
124
+ Only the interactive screen gets peekme: `claude`, `claude "prompt"`, `claude --resume`,
125
+ `claude -c`, `codex`, `codex "prompt"`, `codex resume`, `codex fork`, and `copilot`,
126
+ `copilot -i "prompt"`, `copilot --resume`. Commands like `claude -p`, `codex exec`, `copilot -p`
110
127
  or `copilot login`, and anything with output going to a pipe or a file, run the agent directly.
111
128
 
112
129
  ## How it works
@@ -117,10 +134,11 @@ what is on your screen.
117
134
 
118
135
  On Alt+P it takes the selection and finds it on the screen:
119
136
 
120
- - Codex full screen: the text Codex highlighted.
121
- - Claude Code and Copilot CLI full screen: the agent copies the selection with an OSC 52 escape
122
- sequence when you release the mouse. peekme reads the text from that sequence as it passes through, and knows
137
+ - Claude Code full screen: Claude copies the selection with an OSC 52 escape sequence when you
138
+ release the mouse. peekme reads the text from that sequence as it passes through, and knows
123
139
  where the drag ended. This also works over SSH.
140
+ - Codex full screen: the text Codex highlighted.
141
+ - Copilot CLI: the same OSC 52 sequence as Claude Code.
124
142
  - Otherwise: your terminal's mouse selection (the X11 PRIMARY selection).
125
143
 
126
144
  Then it redraws only the rows next to the selection, with the box between them. Nothing is
@@ -130,7 +148,7 @@ that arrives while the box is open is kept aside.
130
148
 
131
149
  On Esc it draws those rows again from a copy taken when the box opened. After that it sends the
132
150
  kept output, so the terminal ends in the same state as if the box never existed. Tests check
133
- this cell by cell on real Codex, Claude Code and Copilot CLI output.
151
+ this cell by cell on real Claude Code, Codex and Copilot CLI output.
134
152
 
135
153
  ### What the model gets
136
154
 
@@ -146,8 +164,8 @@ slow. So the model gets small parts, each with a size limit:
146
164
  3. Your request that this text answers, and one line for each of your earlier requests.
147
165
  4. The first places in the conversation where the same words were used before.
148
166
 
149
- The conversation comes from Codex's app-server, from Claude Code's session transcript in
150
- `~/.claude/projects`, or from Copilot CLI's session log in `~/.copilot/session-state`. peekme
167
+ The conversation comes from Claude Code's session transcript in `~/.claude/projects`, from
168
+ Codex's app-server, or from Copilot CLI's session log in `~/.copilot/session-state`. peekme
151
169
  knows which session, because the agent registers its process id there.
152
170
 
153
171
  Usually this is 1 to 7 KB of text. When it is not enough, press Alt+P again and the model gets
@@ -159,23 +177,23 @@ more.
159
177
 
160
178
  | Variable | Meaning |
161
179
  |---|---|
180
+ | `PEEKME_CLAUDE_MODEL` | model for Claude Code explanations. Default is `haiku` |
181
+ | `PEEKME_CLAUDE_BIN` | claude binary to use for explanations. Default is `claude` |
162
182
  | `PEEKME_MODEL` | model for Codex explanations. Default is the model your account lists as fast |
163
183
  | `PEEKME_CODEX_BIN` | codex binary to use for explanations. Default is `codex` |
164
184
  | `PEEKME_OWN_SERVER` | set to 1 to start peekme's own `codex app-server` instead of using the shared one |
165
- | `PEEKME_CLAUDE_MODEL` | model for Claude Code explanations. Default is `haiku` |
166
- | `PEEKME_CLAUDE_BIN` | claude binary to use for explanations. Default is `claude` |
167
185
  | `PEEKME_COPILOT_MODEL` | model for Copilot CLI explanations. Default is Copilot's Auto |
168
186
  | `PEEKME_COPILOT_BIN` | copilot binary to use for explanations. Default is `copilot` |
169
187
  | `PEEKME_SELECTION` | use this text instead of the mouse selection, for testing |
170
188
 
171
- ### How `codex`, `claude` and `copilot` get peekme
189
+ ### How `claude`, `codex` and `copilot` get peekme
172
190
 
173
191
  `peekme install` does two things:
174
192
 
175
- 1. It defines shell functions `codex`, `claude` and `copilot` in your shell setup. A function wins over
193
+ 1. It defines shell functions `claude`, `codex` and `copilot` in your shell setup. A function wins over
176
194
  anything on PATH, so it keeps working when nvm, mise, Homebrew or an agent's installer
177
195
  change PATH later. Aliases that call them go through it too.
178
- 2. It puts `codex`, `claude` and `copilot` links to peekme in `~/.local/share/peekme/bin` at the front of
196
+ 2. It puts `claude`, `codex` and `copilot` links to peekme in `~/.local/share/peekme/bin` at the front of
179
197
  PATH, so scripts that run them also get peekme. If some tool puts its own directory in front
180
198
  of it later, only scripts lose peekme, and `peekme doctor` tells you which directory it is.
181
199
 
@@ -218,7 +236,7 @@ shows if your terminal flickers when a program switches screens. `explain_probe.
218
236
  explanation request to `codex app-server` and prints timings. `copilot_probe.py` does the same
219
237
  with Copilot CLI's headless server.
220
238
 
221
- Each agent has its own folder in `src/` (`codex/`, `claude/`, `copilot/`): how its selection is read, where
239
+ Each agent has its own folder in `src/` (`claude/`, `codex/`, `copilot/`): how its selection is read, where
222
240
  its conversation comes from, and which model explains. The rest is shared.
223
241
 
224
242
  ## License
@@ -19,7 +19,7 @@
19
19
  "hasInstallScript": true,
20
20
  "license": "MIT OR Apache-2.0",
21
21
  "name": "peekme",
22
- "version": "0.3.2"
22
+ "version": "0.3.3"
23
23
  },
24
24
  "node_modules/detect-libc": {
25
25
  "engines": {
@@ -48,5 +48,5 @@
48
48
  }
49
49
  },
50
50
  "requires": true,
51
- "version": "0.3.2"
51
+ "version": "0.3.3"
52
52
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "artifactDownloadUrls": [
3
- "https://github.com/GregoryBolshakov/peekme/releases/download/v0.3.2"
3
+ "https://github.com/GregoryBolshakov/peekme/releases/download/v0.3.3"
4
4
  ],
5
5
  "author": "Gregory Bolshakov",
6
6
  "bin": {
@@ -9,7 +9,7 @@
9
9
  "dependencies": {
10
10
  "detect-libc": "^2.1.2"
11
11
  },
12
- "description": "Select text in Codex CLI, Claude Code or GitHub Copilot CLI output and get a short explanation right under it, inside the terminal",
12
+ "description": "Select text in Claude Code, Codex CLI or GitHub Copilot CLI output and get a short explanation right under it, inside the terminal",
13
13
  "devDependencies": {
14
14
  "prettier": "^3.8.3"
15
15
  },
@@ -24,8 +24,8 @@
24
24
  "homepage": "https://github.com/GregoryBolshakov/peekme",
25
25
  "keywords": [
26
26
  "command-line-utilities",
27
- "codex",
28
27
  "claude",
28
+ "codex",
29
29
  "copilot",
30
30
  "terminal",
31
31
  "cli"
@@ -69,7 +69,7 @@
69
69
  "zipExt": ".tar.xz"
70
70
  }
71
71
  },
72
- "version": "0.3.2",
72
+ "version": "0.3.3",
73
73
  "volta": {
74
74
  "node": "18.14.1",
75
75
  "npm": "9.5.0"