githits 0.4.3 → 0.4.5
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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/.plugin/plugin.json +1 -1
- package/GEMINI.md +4 -3
- package/README.md +41 -15
- package/commands/example.md +2 -1
- package/commands/help.md +1 -1
- package/commands/search.md +2 -1
- package/dist/cli.js +2348 -449
- package/dist/index.js +1 -1
- package/dist/shared/{chunk-q6d3ttgn.js → chunk-vfyz65v1.js} +1 -1
- package/dist/shared/{chunk-15argn2z.js → chunk-ygqss6gp.js} +651 -49
- package/dist/shared/chunk-zzmbjttb.js +15 -0
- package/gemini-extension.json +1 -1
- package/package.json +3 -1
- package/plugins/claude/.claude-plugin/plugin.json +1 -1
- package/plugins/claude/commands/example.md +2 -1
- package/plugins/claude/commands/help.md +1 -1
- package/plugins/claude/commands/search.md +2 -1
- package/plugins/claude/skills/search/SKILL.md +2 -0
- package/skills/githits-code/SKILL.md +81 -0
- package/skills/githits-code/references/code-and-docs.md +49 -0
- package/skills/githits-package/SKILL.md +90 -0
- package/skills/githits-package/references/package.md +51 -0
- package/dist/shared/chunk-kmka6wpx.js +0 -11
- package/skills/search/SKILL.md +0 -40
package/.plugin/plugin.json
CHANGED
package/GEMINI.md
CHANGED
|
@@ -24,13 +24,14 @@ Look up supported programming language names. Use this before calling `get_examp
|
|
|
24
24
|
|
|
25
25
|
### feedback
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
Submit feedback on a search result, a GitHits tool result, or the current GitHits session. Use it when a result was useful or when a tool/UX issue should be recorded.
|
|
28
28
|
|
|
29
29
|
**Parameters:**
|
|
30
30
|
|
|
31
|
-
- `solution_id` (string,
|
|
31
|
+
- `solution_id` (string, optional) - ID from a `get_example` result; omit for generic session feedback
|
|
32
32
|
- `accepted` (boolean, required) - whether the result was useful
|
|
33
33
|
- `feedback_text` (string, optional) - additional context about why the result was or was not helpful
|
|
34
|
+
- `tool_name` (string, optional) - GitHits tool or command being rated for generic feedback
|
|
34
35
|
|
|
35
36
|
## When to Use
|
|
36
37
|
|
|
@@ -64,7 +65,7 @@ Do not use `get_example` for:
|
|
|
64
65
|
- Formulate queries as natural language questions (e.g., "How to stream responses with the Vercel AI SDK in Next.js")
|
|
65
66
|
- Include specific error messages, library names, or API names when relevant
|
|
66
67
|
- Keep queries focused: 3-4 technical terms maximum
|
|
67
|
-
- Submit `feedback` after
|
|
68
|
+
- Submit `feedback` after GitHits results you use or discard; omit `solution_id` for generic tool/session feedback
|
|
68
69
|
|
|
69
70
|
## Indexed Package/Source Tools
|
|
70
71
|
|
package/README.md
CHANGED
|
@@ -94,7 +94,7 @@ Core tools available in every authenticated session:
|
|
|
94
94
|
|---|---|
|
|
95
95
|
| `get_example` | Find canonical code examples by describing what you need in natural language |
|
|
96
96
|
| `search_language` | Look up supported programming language names |
|
|
97
|
-
| `feedback` |
|
|
97
|
+
| `feedback` | Submit result or session feedback to improve future quality |
|
|
98
98
|
|
|
99
99
|
The assistant decides when to call these tools on its own — typically when it's stuck, needs a working example for an unfamiliar API, or encounters an error it can't resolve from its training data alone.
|
|
100
100
|
|
|
@@ -132,7 +132,7 @@ GitHits requires authentication. There are two options:
|
|
|
132
132
|
npx githits login
|
|
133
133
|
```
|
|
134
134
|
|
|
135
|
-
Opens your browser for secure OAuth authentication. Tokens are stored in the system keychain by default and refreshed automatically on next use. If a refresh fails (
|
|
135
|
+
Opens your browser for secure OAuth authentication. Tokens are stored in the system keychain by default and refreshed automatically on next use. If a refresh fails (for example, after an extended idle period), run `githits login` again.
|
|
136
136
|
|
|
137
137
|
Useful flags:
|
|
138
138
|
|
|
@@ -148,30 +148,54 @@ For CI or environments where browser login isn't practical, set an environment v
|
|
|
148
148
|
export GITHITS_API_TOKEN=ghi-your-token-here
|
|
149
149
|
```
|
|
150
150
|
|
|
151
|
-
|
|
151
|
+
### Keychain Prompts and File Storage
|
|
152
|
+
|
|
153
|
+
GitHits uses the system keychain by default because OAuth credentials include a refresh token. On macOS this means Keychain Access; on Windows it means Credential Manager; on Linux it means the available Secret Service or keyring backend.
|
|
154
|
+
|
|
155
|
+
If macOS shows a prompt such as "githits wants to access ... in your keychain", choose **Always Allow** when you trust the installed `githits` CLI. GitHits cannot customize that operating-system prompt with extra explanation; it is generated by macOS.
|
|
156
|
+
|
|
157
|
+
GitHits also writes a small non-secret metadata file so recent startup checks do not need to read the keychain. The keychain is only read when GitHits actually needs the token, for example during a tool call, token refresh, `githits auth status`, or a login check after metadata is stale or expired.
|
|
158
|
+
|
|
159
|
+
If your agent keeps showing keychain prompts even after **Always Allow**, switch OAuth storage to file mode:
|
|
152
160
|
|
|
153
161
|
```toml
|
|
154
|
-
# ~/.config/githits/config.toml
|
|
162
|
+
# macOS/Linux: ~/.config/githits/config.toml, or $XDG_CONFIG_HOME/githits/config.toml
|
|
163
|
+
# Windows: %APPDATA%\githits\config.toml
|
|
155
164
|
[auth]
|
|
156
165
|
storage = "file"
|
|
157
166
|
```
|
|
158
167
|
|
|
159
|
-
|
|
168
|
+
The config directory may be empty until you create `config.toml` or GitHits writes auth metadata. Older macOS installs may have used `~/Library/Application Support/githits`; GitHits still reads that location for migration, but new auth config and file storage use `~/.config/githits`.
|
|
169
|
+
|
|
170
|
+
You can also opt in for one process:
|
|
171
|
+
|
|
172
|
+
```sh
|
|
173
|
+
GITHITS_AUTH_STORAGE=file githits login --force
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
File mode stores OAuth credentials as JSON files under the GitHits config directory. The files are written with private permissions where the platform supports it, but they are not encrypted. Any process that can read files as your operating-system user may be able to read the tokens.
|
|
160
177
|
|
|
161
|
-
|
|
178
|
+
Use file mode only on machines where you trust local user-account access. For CI and automation, prefer `GITHITS_API_TOKEN` instead of browser OAuth.
|
|
179
|
+
|
|
180
|
+
To inspect the current auth setup, run:
|
|
181
|
+
|
|
182
|
+
```sh
|
|
183
|
+
githits auth status
|
|
184
|
+
```
|
|
162
185
|
|
|
163
186
|
## Commands
|
|
164
187
|
|
|
165
188
|
```
|
|
166
|
-
githits init
|
|
167
|
-
githits
|
|
168
|
-
githits
|
|
169
|
-
githits
|
|
170
|
-
githits mcp
|
|
171
|
-
githits
|
|
172
|
-
githits
|
|
173
|
-
githits
|
|
174
|
-
githits
|
|
189
|
+
githits init Authenticate and configure your coding tools with GitHits MCP
|
|
190
|
+
githits init uninstall Remove GitHits MCP configuration from your coding tools
|
|
191
|
+
githits login Authenticate with your GitHits account (also runs as part of init)
|
|
192
|
+
githits logout Remove stored credentials
|
|
193
|
+
githits mcp Show setup instructions in a terminal; starts MCP server when piped
|
|
194
|
+
githits mcp start Always start MCP server (for use in MCP config files)
|
|
195
|
+
githits auth status Show current authentication status
|
|
196
|
+
githits example Get canonical code examples from global open source
|
|
197
|
+
githits languages List or filter supported language names
|
|
198
|
+
githits feedback Send feedback on a result, command, or session
|
|
175
199
|
```
|
|
176
200
|
|
|
177
201
|
These indexed package/source commands are also available:
|
|
@@ -223,6 +247,8 @@ A typical MCP config looks like this (check your tool's docs for exact schema/ke
|
|
|
223
247
|
|
|
224
248
|
If you'd like another tool to be included in `githits init` for auto-configuration, open an issue or PR.
|
|
225
249
|
|
|
250
|
+
To undo automatic setup, run `githits init uninstall`. It removes only GitHits MCP/plugin configuration and preserves stored credentials; use `githits logout` separately to remove credentials.
|
|
251
|
+
|
|
226
252
|
## Development
|
|
227
253
|
|
|
228
254
|
```sh
|
package/commands/example.md
CHANGED
|
@@ -21,4 +21,5 @@ Optional parameters:
|
|
|
21
21
|
licenses), or `"custom"` (user's blocklist).
|
|
22
22
|
|
|
23
23
|
Present the results clearly. After the user has reviewed the result, use the
|
|
24
|
-
`feedback` tool to report whether the example was helpful.
|
|
24
|
+
`feedback` tool to report whether the example was helpful. Use the returned
|
|
25
|
+
`solution_id` when available.
|
package/commands/help.md
CHANGED
|
@@ -31,7 +31,7 @@ This plugin connects to the GitHits MCP server and always exposes these core too
|
|
|
31
31
|
language. Requires `query`; `language` is optional and inferred when omitted.
|
|
32
32
|
- **search_language** — Look up supported programming language names when you
|
|
33
33
|
need to force a specific language.
|
|
34
|
-
- **feedback** —
|
|
34
|
+
- **feedback** — Submit result or session feedback to improve future quality.
|
|
35
35
|
|
|
36
36
|
Additional indexed dependency/package tools are available by default:
|
|
37
37
|
`search`, `search_status`, `docs_list`, `docs_read`, `pkg_info`, `pkg_vulns`,
|
package/commands/search.md
CHANGED
|
@@ -23,4 +23,5 @@ Optional parameters:
|
|
|
23
23
|
licenses), or `"custom"` (user's blocklist).
|
|
24
24
|
|
|
25
25
|
Present the results clearly. After the user has reviewed the result, use the
|
|
26
|
-
`feedback` tool to report whether the
|
|
26
|
+
`feedback` tool to report whether the result was helpful. Omit `solution_id`
|
|
27
|
+
for generic session feedback about indexed search results.
|