trelly 0.2.0 → 0.2.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trelly",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "trelly — fast Trello CLI with multi-profile auth, MCP server, and kanban TUI",
5
5
  "type": "module",
6
6
  "license": "MIT",
package/skills/README.md CHANGED
@@ -6,8 +6,8 @@ developing this repo.
6
6
 
7
7
  | Skill | Use when |
8
8
  |-------|----------|
9
- | [trelly](trelly/SKILL.md) | Terminal / bash: `trelly boards list`, auth, `--json` |
10
- | [trelly-mcp](trelly-mcp/SKILL.md) | IDE agent with MCP wired: tool names, envelopes, safety |
9
+ | [trelly](trelly/SKILL.md) | Terminal / bash: `trelly boards list`, auth, attachments, GitHub PR/commit links, `--json` |
10
+ | [trelly-mcp](trelly-mcp/SKILL.md) | IDE agent with MCP wired: tool names, GitHub links via `trello_api`, envelopes, safety |
11
11
 
12
12
  **One copy of the content:** `skills/trelly/` and `skills/trelly-mcp/` in the installed
13
13
  package. Plugins and Pi load from there — you don't maintain separate copies.
@@ -2,9 +2,9 @@
2
2
  name: trelly
3
3
  description: >-
4
4
  Operate the trelly Trello CLI (npm trelly; bins trelly/trello): auth setup/login,
5
- human vs --json output, boards/lists/cards, search, trello ui, trello api. Use when
6
- the user asks to run trelly/trello commands, script Trello from the terminal, or
7
- automate Trello with trelly.
5
+ human vs --json output, boards/lists/cards, search, attachments, GitHub PR/commit
6
+ links on cards, trello ui, trello api. Use when the user asks to run trelly/trello
7
+ commands, link a GitHub PR or commit to a Trello card, or automate Trello with trelly.
8
8
  ---
9
9
 
10
10
  # trelly
@@ -56,6 +56,8 @@ trelly cards comments CARD_ID
56
56
  trelly cards create --list LIST_ID --name "Task"
57
57
  trelly cards move CARD_ID --list OTHER_LIST_ID
58
58
  trelly cards comment CARD_ID --text "Done"
59
+ trelly cards attachments CARD_ID
60
+ trelly cards add-attachment CARD_ID --url "https://github.com/org/repo/pull/42"
59
61
  trelly search "query"
60
62
  trelly ui BOARD_ID # interactive kanban (TTY required)
61
63
  trelly auth list
@@ -73,6 +75,89 @@ trelly api -X POST --path /cards --body '{"idList":"LIST_ID","name":"Hi"}'
73
75
 
74
76
  Request body flag is **`--body`** (not `--json` — that flag is global output).
75
77
 
78
+ ## Card attachments
79
+
80
+ ```bash
81
+ trelly cards attachments CARD_ID
82
+ trelly cards add-attachment CARD_ID --url "https://…" [--name "label"]
83
+ trelly cards add-attachment CARD_ID --file ./screenshot.png [--name "label"]
84
+ trelly cards delete-attachment CARD_ID ATTACHMENT_ID
85
+ ```
86
+
87
+ Pass **exactly one** of `--url` or `--file`. In `trelly ui`, open a card's detail (**⏎**), then **a** opens the attach prompt (URL or local path).
88
+
89
+ ## GitHub PR / commit on a card
90
+
91
+ Boards with the **GitHub Power-Up** enabled can show rich PR metadata in the Trello UI.
92
+ trelly attaches the same underlying **URL attachment** — it does **not** drive the
93
+ Power-Up picker or OAuth flow.
94
+
95
+ ### Link a PR or commit (preferred)
96
+
97
+ ```bash
98
+ # Pull request — set --name so the attachment is scannable in lists/UI
99
+ trelly cards add-attachment CARD_ID \
100
+ --url "https://github.com/PangoliaDev/dogster/pull/197" \
101
+ --name "#197 fix(pre-existing-tests-and-types)"
102
+
103
+ # Commit
104
+ trelly cards add-attachment CARD_ID \
105
+ --url "https://github.com/PangoliaDev/dogster/commit/2d856ea" \
106
+ --name "2d856ea Merge PR #197"
107
+
108
+ # Issue (same mechanism)
109
+ trelly cards add-attachment CARD_ID \
110
+ --url "https://github.com/PangoliaDev/dogster/issues/42"
111
+ ```
112
+
113
+ Accepted URL shapes: `…/pull/N`, `…/commit/SHA`, `…/issues/N`, `…/tree/branch`.
114
+ Use the canonical `https://github.com/…` URL (no `/files` or `/commits` tab suffix).
115
+
116
+ ### Power-Up UI vs trelly URL attachment
117
+
118
+ | Feature | GitHub Power-Up (Trello UI) | `cards add-attachment --url` |
119
+ |--------|-----------------------------|------------------------------|
120
+ | Link on card | Yes | Yes |
121
+ | Readable `--name` / PR title | Yes (auto) | Set `--name` yourself (recommended) |
122
+ | CI/check badges on card front | Yes | No |
123
+ | Pick PR from repo browser | Yes | No — pass URL |
124
+ | Comment back on GitHub PR | Yes (optional setting) | No |
125
+
126
+ If the user needs badges or GitHub-side back-links, attach via **Power-Ups → GitHub**
127
+ in Trello. For agent/CLI workflows (ship PR → link card → move list), URL attachment
128
+ is enough.
129
+
130
+ ### Agent workflow patterns
131
+
132
+ **After opening or merging a PR** — attach and optionally move the card:
133
+
134
+ ```bash
135
+ CARD_ID=…
136
+ PR_URL="https://github.com/PangoliaDev/dogster/pull/197"
137
+ trelly cards add-attachment "$CARD_ID" --url "$PR_URL" --name "#197 fix scope"
138
+ trelly cards move "$CARD_ID" --list PENDING_REVIEW_LIST_ID
139
+ ```
140
+
141
+ **Fallback — comment only** (visible in activity, not Attachments):
142
+
143
+ ```bash
144
+ trelly cards comment CARD_ID --text "PR: https://github.com/org/repo/pull/42"
145
+ ```
146
+
147
+ **Inspect what's linked:**
148
+
149
+ ```bash
150
+ trelly --json cards attachments CARD_ID | jq '.data[] | {name, url}'
151
+ ```
152
+
153
+ ### Raw API (same as CLI)
154
+
155
+ ```bash
156
+ trelly api -X POST --path "/cards/CARD_ID/attachments" \
157
+ --query "url=https://github.com/org/repo/pull/42" \
158
+ --query "name=#42 feature title"
159
+ ```
160
+
76
161
  ## Custom fields (list-type)
77
162
 
78
163
  ```bash
@@ -2,8 +2,8 @@
2
2
  name: trelly-mcp
3
3
  description: >-
4
4
  Configure and use the trelly MCP stdio server (trello_boards_list,
5
- trello_card_create, trello_search, etc.). Use when wiring Cursor/Claude MCP,
6
- calling Trello from an IDE agent, or choosing between MCP tools vs trelly CLI.
5
+ trello_card_create, trello_search, trello_api, etc.). Use when wiring Cursor/Claude
6
+ MCP, linking GitHub PRs/commits to Trello cards from an agent, or choosing MCP vs CLI.
7
7
  ---
8
8
 
9
9
  # trelly-mcp
@@ -99,6 +99,66 @@ Starts stdio MCP manually (IDE normally launches `trelly-mcp` itself).
99
99
  | `trello_webhook_delete` | Delete webhook |
100
100
  | `trello_api` | Raw REST (`method`, `path`, `query`, `body`) |
101
101
 
102
+ There is **no dedicated attachment MCP tool** yet — use `trello_api` or the CLI
103
+ `cards add-attachment` (see **trelly** skill).
104
+
105
+ ## GitHub PR / commit on a card (MCP)
106
+
107
+ Boards with the **GitHub Power-Up** show rich PR UI when attached through Trello.
108
+ Agents link the same way via **`trello_api`** — a URL attachment, not the Power-Up
109
+ OAuth picker.
110
+
111
+ ### Attach PR or commit
112
+
113
+ ```
114
+ trello_api
115
+ method: POST
116
+ path: /cards/{cardId}/attachments
117
+ query: { "url": "https://github.com/org/repo/pull/42", "name": "#42 feature title" }
118
+ ```
119
+
120
+ Commit:
121
+
122
+ ```
123
+ query: { "url": "https://github.com/org/repo/commit/abc1234", "name": "abc1234 message" }
124
+ ```
125
+
126
+ Always set **`name`** to something scannable (`#N title` or short SHA + subject).
127
+
128
+ ### List or remove attachments
129
+
130
+ ```
131
+ trello_api GET /cards/{cardId}/attachments
132
+ trello_api DELETE /cards/{cardId}/attachments/{attachmentId}
133
+ ```
134
+
135
+ ### Comment fallback
136
+
137
+ ```
138
+ trello_card_comment cardId text: "PR: https://github.com/org/repo/pull/42"
139
+ ```
140
+
141
+ Comments appear in card activity; they are **not** Attachments.
142
+
143
+ ### Power-Up vs MCP/API
144
+
145
+ | Feature | GitHub Power-Up (UI) | `trello_api` URL attachment |
146
+ |--------|----------------------|-----------------------------|
147
+ | Link on card | Yes | Yes |
148
+ | PR title / custom name | Auto | Set `name` in query |
149
+ | CI badges on card front | Yes | No |
150
+ | GitHub PR back-link comment | Yes (optional) | No |
151
+
152
+ Use the Power-Up UI when the user needs badges or GitHub-side comments. For
153
+ agent workflows (link PR after push, move card to review), POST the GitHub URL.
154
+
155
+ ### Typical agent sequence
156
+
157
+ 1. `trello_search` or `trello_list_cards` — find the card
158
+ 2. `trello_api` POST `/cards/{id}/attachments` with PR URL + name
159
+ 3. `trello_card_move` — e.g. To do → Pending review
160
+ 4. Optional: `trello_card_comment` with the same PR URL
161
+
102
162
  ## When to use MCP vs CLI
103
163
 
104
164
  | Use MCP | Use CLI |