githits 0.2.3 → 0.3.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.
@@ -6,7 +6,7 @@
6
6
  },
7
7
  "metadata": {
8
8
  "description": "GitHits plugins for Claude Code - code examples from global open source",
9
- "version": "0.2.3"
9
+ "version": "0.3.1"
10
10
  },
11
11
  "plugins": [
12
12
  {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "githits",
3
- "version": "0.2.3",
3
+ "version": "0.3.1",
4
4
  "description": "Code examples from global open source for developers and AI assistants",
5
5
  "author": {
6
6
  "name": "GitHits"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "githits",
3
- "version": "0.2.3",
3
+ "version": "0.3.1",
4
4
  "description": "Code examples from global open source for developers and AI assistants",
5
5
  "author": {
6
6
  "name": "GitHits"
package/GEMINI.md CHANGED
@@ -66,13 +66,11 @@ Do not use `get_example` for:
66
66
  - Keep queries focused: 3-4 technical terms maximum
67
67
  - Submit `feedback` after every search result you use or discard
68
68
 
69
- ## Feature-Gated Tools
69
+ ## Indexed Package/Source Tools
70
70
 
71
- When the authenticated token carries the `code_navigation` feature flag, GitHits
72
- also exposes indexed dependency/package tools such as `search`,
73
- `search_status`, `package_summary`, `package_vulnerabilities`,
74
- `package_dependencies`, `package_changelog`, `list_files`, `read_file`, and
75
- `grep_repo`.
71
+ GitHits also exposes indexed dependency/package tools such as `search`,
72
+ `search_status`, `docs_list`, `docs_read`, `pkg_info`, `pkg_vulns`,
73
+ `pkg_deps`, `pkg_changelog`, `code_files`, `code_read`, and `code_grep`.
76
74
 
77
75
  ## License Filtering
78
76
 
package/README.md CHANGED
@@ -12,7 +12,7 @@ npx githits init
12
12
 
13
13
  `init` authenticates with your [GitHits](https://githits.com) account, then auto-detects your installed coding tools and configures each one with GitHits MCP.
14
14
 
15
- Supported tools: Claude Code, Cursor, Windsurf, VS Code / Copilot, Cline, Claude Desktop, Codex CLI, Gemini CLI, and Google Antigravity.
15
+ Supported tools: Claude Code, Cursor, Windsurf, VS Code / Copilot, Cline, Claude Desktop, Codex CLI, Gemini CLI, Google Antigravity, and OpenCode.
16
16
 
17
17
  If you are using a tool that is not listed above, use the manual MCP setup instructions near the end of this README.
18
18
 
@@ -82,7 +82,7 @@ For plugin-based hosts, install from npm/GitHub using your agent's plugin workfl
82
82
  - **GitHub Copilot**: supports Open Plugin components
83
83
  - **Gemini CLI**: supports `gemini-extension.json` and `GEMINI.md`
84
84
 
85
- That's it. Your assistant now has GitHits example-search tools, and on accounts with package/source access enabled it also gets indexed dependency/package inspection tools.
85
+ That's it. Your assistant now has GitHits example-search tools and indexed dependency/package inspection tools.
86
86
 
87
87
  ## How It Works
88
88
 
@@ -98,21 +98,21 @@ Core tools available in every authenticated session:
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
 
101
- When package/source access is enabled for the current token, GitHits also exposes these capability-gated tools:
101
+ GitHits also exposes indexed package/source tools:
102
102
 
103
103
  | Tool | Purpose |
104
104
  |---|---|
105
105
  | `search` | Unified indexed search across dependency/repository code, docs, and symbols |
106
106
  | `search_status` | Follow up a prior indexed `search` by `searchRef` |
107
- | `package_summary` | Quick package overview: version, license, downloads, quickstart, advisories |
108
- | `package_vulnerabilities` | CVE / OSV advisories for a package or specific version |
109
- | `package_dependencies` | Direct dependencies, dependency groups, and optional transitive graph |
110
- | `package_changelog` | Release notes / changelog entries for a package or GitHub repo |
111
- | `list_files` | Discover what files a dependency or repo contains |
112
- | `read_file` | Read a dependency file by path |
113
- | `grep_repo` | Deterministic text grep across indexed dependency or repo files |
114
-
115
- These advanced tools remain feature-gated. The MCP server advertises them only when the authenticated token explicitly carries the `code_navigation` feature flag.
107
+ | `docs_list` | Browse mixed package documentation pages |
108
+ | `docs_read` | Read a documentation page by page ID |
109
+ | `pkg_info` | Quick package overview: version, license, downloads, quickstart, advisories |
110
+ | `pkg_vulns` | CVE / OSV advisories for a package or specific version |
111
+ | `pkg_deps` | Direct dependencies, dependency groups, and optional transitive graph |
112
+ | `pkg_changelog` | Release notes / changelog entries for a package or GitHub repo |
113
+ | `code_files` | Discover what files a dependency or repo contains |
114
+ | `code_read` | Read a dependency file by path |
115
+ | `code_grep` | Deterministic text grep across indexed dependency or repo files |
116
116
 
117
117
  ### License Filtering
118
118
 
@@ -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 locally and refreshed automatically on next use. If a refresh fails (e.g., after an extended idle period), run `githits login` again.
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 (e.g., after an extended idle period), run `githits login` again.
136
136
 
137
137
  Useful flags:
138
138
 
@@ -148,6 +148,18 @@ 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
+ For machines without a usable keychain, OAuth file storage must be explicit:
152
+
153
+ ```toml
154
+ # ~/.config/githits/config.toml on Linux
155
+ [auth]
156
+ storage = "file"
157
+ ```
158
+
159
+ File storage is plaintext on disk. Prefer `GITHITS_API_TOKEN` for CI and automation.
160
+
161
+ You can also opt in for one process with `GITHITS_AUTH_STORAGE=file`. Use file storage only on machines where local file access is trusted.
162
+
151
163
  ## Commands
152
164
 
153
165
  ```
@@ -162,12 +174,13 @@ githits languages List or filter supported language names
162
174
  githits feedback Send feedback on a returned example
163
175
  ```
164
176
 
165
- When the current token explicitly carries `code_navigation`, these extra commands are also available:
177
+ These indexed package/source commands are also available:
166
178
 
167
179
  ```
168
180
  githits search ... Unified indexed dependency/repository search
169
181
  githits search-status Follow up a prior indexed search
170
182
  githits pkg ... Package metadata: overview, advisories, deps, changelog
183
+ githits docs ... Package documentation: browse pages and read content
171
184
  githits code ... Dependency source inspection: search, files, read, grep
172
185
  ```
173
186
 
@@ -176,17 +189,18 @@ githits code ... Dependency source inspection: search, files, read, grep
176
189
  | Variable | Purpose | Default |
177
190
  |---|---|---|
178
191
  | `GITHITS_API_TOKEN` | API token for authentication | — |
192
+ | `GITHITS_AUTH_STORAGE` | Override OAuth storage mode (`keychain` or `file`) | `keychain` |
179
193
  | `GITHITS_MCP_URL` | Override MCP server URL | `https://mcp.githits.com` |
180
194
  | `GITHITS_API_URL` | Override REST API URL | `https://api.githits.com` |
181
- | `GITHITS_CODE_NAV_URL` | Override package/source service URL | environment-specific |
182
- | `GITHITS_CODE_NAVIGATION` | Expose hidden `search` / `pkg` / `code` CLI surfaces locally for development | — |
195
+ | `GITHITS_CODE_NAV_URL` | Override package/source service URL | `https://pkgseer.dev` |
183
196
  | `GITHITS_TELEMETRY` | Emit end-of-run timing spans to stderr for local profiling | — |
197
+ | `GITHITS_DISABLE_UPDATE_CHECK` | Disable npm latest-version update notices | — |
184
198
 
185
199
  ## Manual Setup
186
200
 
187
201
  If your tool is not in the supported `githits init` list, configure GitHits manually.
188
202
 
189
- The same MCP server command exposes both the core example-search tools and, when your token carries `code_navigation`, the indexed package/source inspection tools. No separate install is required.
203
+ The same MCP server command exposes both the core example-search tools and the indexed package/source inspection tools. No separate install is required.
190
204
 
191
205
  Use this MCP server command in your tool's MCP config (the host/agent runs this command):
192
206
 
package/commands/help.md CHANGED
@@ -25,7 +25,7 @@ context summary:
25
25
 
26
26
  ## MCP Tools
27
27
 
28
- This plugin connects to the GitHits MCP server and always exposes three core tools:
28
+ This plugin connects to the GitHits MCP server and always exposes these core tools:
29
29
 
30
30
  - **get_example** — Find code examples by describing what you need in natural
31
31
  language. Requires `query`; `language` is optional and inferred when omitted.
@@ -33,9 +33,9 @@ This plugin connects to the GitHits MCP server and always exposes three core too
33
33
  need to force a specific language.
34
34
  - **feedback** — Rate a search result to improve future quality.
35
35
 
36
- Additional indexed dependency/package tools such as `search`, `package_summary`,
37
- `list_files`, and `grep_repo` stay hidden unless the authenticated token carries
38
- the `code_navigation` feature flag.
36
+ Additional indexed dependency/package tools are available by default:
37
+ `search`, `search_status`, `docs_list`, `docs_read`, `pkg_info`, `pkg_vulns`,
38
+ `pkg_deps`, `pkg_changelog`, `code_files`, `code_read`, and `code_grep`.
39
39
 
40
40
  ## Authentication
41
41