Skip to content

Commit dbaa5d3

Browse files
AddonoCopilot
andauthored
docs: pin npx usage to @latest (#87)
Update npx usage examples to use gh-attach@latest and -y by default so the docs always resolve the latest published package. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 4f24def commit dbaa5d3

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,10 @@ Run it as `gh-attach ...`.
6464

6565
```bash
6666
# Upload a file
67-
npx gh-attach upload ./screenshot.png --target owner/repo#42
67+
npx -y gh-attach@latest upload ./screenshot.png --target owner/repo#42
6868

6969
# Start the MCP server
70-
npx gh-attach mcp --transport stdio
70+
npx -y gh-attach@latest mcp --transport stdio
7171
```
7272

7373
## Keeping gh-attach up to date
@@ -80,10 +80,10 @@ npm install -g gh-attach@latest
8080
gh extension upgrade Addono/gh-attach
8181
```
8282

83-
If you run via `npx`, there is nothing to upgrade locally — each invocation resolves the published package. Pin a version explicitly if you do not want the latest release:
83+
If you run via `npx`, there is nothing to upgrade locally — each invocation resolves `gh-attach@latest`. Pin a specific version instead if you do not want the latest release:
8484

8585
```bash
86-
npx gh-attach@<version> mcp --transport stdio
86+
npx -y gh-attach@<version> mcp --transport stdio
8787
```
8888

8989
If you installed a standalone release binary, download the newest matching asset from the latest GitHub release and replace your existing `gh-attach` executable.
@@ -150,7 +150,7 @@ Choose the MCP command that matches how you installed `gh-attach`:
150150
| Standalone npm install | `gh-attach mcp --transport stdio` |
151151
| Standalone release binary | `gh-attach mcp --transport stdio` |
152152
| `gh` extension | `gh attach mcp --transport stdio` |
153-
| `npx` | `npx gh-attach mcp --transport stdio` |
153+
| `npx` | `npx -y gh-attach@latest mcp --transport stdio` |
154154

155155
When the MCP client supports elicitation, `upload_image` can prompt for a GitHub token during the same tool call and continue the upload without requiring a separate `login` step first.
156156

@@ -243,7 +243,7 @@ Add to `.vscode/settings.json`:
243243

244244
This wrapper requires `bash` and an authenticated GitHub CLI session (`gh auth login`). It resolves the token at startup instead of storing it in the config file, but the token is still present in the MCP server process environment while it is running. If `bash` is unavailable, use the standalone CLI setup instead.
245245

246-
If you prefer `npx`, use `command: "npx"` and prepend `gh-attach` to the `args` array.
246+
If you prefer `npx`, use `command: "npx"` and prepend `-y`, `gh-attach@latest` to the `args` array.
247247

248248
## Configuration
249249

0 commit comments

Comments
 (0)