@lifeaitools/rdc-skills 0.9.14 → 0.9.15
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 +1 -1
- package/skills/lab-push/SKILL.md +0 -46
package/package.json
CHANGED
package/skills/lab-push/SKILL.md
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: rdc:lab-push
|
|
3
|
-
description: >-
|
|
4
|
-
Usage `rdc:lab-push <filename>` — push the artifact in this conversation to the Lab prototype viewer. Commits the file to apps/lab/docs/prototypes/ via POST https://lab.dev.place.fund/api/prototypes/push. Viewable immediately at lab.dev.place.fund/proto/<filename>.
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# rdc:lab-push — Push Artifact to Lab
|
|
8
|
-
|
|
9
|
-
Push a JSX, TSX, HTML, or JS artifact from this conversation to the Lab prototype viewer at `lab.dev.place.fund`.
|
|
10
|
-
|
|
11
|
-
## How it works
|
|
12
|
-
|
|
13
|
-
1. POST `{ filename, content }` to `https://lab.dev.place.fund/api/prototypes/push`
|
|
14
|
-
2. The endpoint commits the file to `apps/lab/docs/prototypes/` on the `develop` branch via the GitHub Contents API
|
|
15
|
-
3. The file is immediately visible at `https://lab.dev.place.fund/proto/<filename>` — no redeploy needed
|
|
16
|
-
|
|
17
|
-
## Usage
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
rdc:lab-push <filename>
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
- `filename` must end in `.jsx`, `.tsx`, `.html`, or `.js`
|
|
24
|
-
- The artifact content comes from this conversation (the most recent code block, or the artifact the user is referring to)
|
|
25
|
-
|
|
26
|
-
## Steps
|
|
27
|
-
|
|
28
|
-
1. Identify the artifact content — the most recent code block in this conversation that the user wants to push, or what they explicitly point to
|
|
29
|
-
2. If filename not provided as an argument, derive one from the artifact (e.g. `my-component.jsx`)
|
|
30
|
-
3. Check if the file already exists: GET `https://lab.dev.place.fund/api/prototypes/content?filename=<filename>` — if it returns a `sha`, include it in the push body so GitHub can update rather than reject
|
|
31
|
-
4. POST to `https://lab.dev.place.fund/api/prototypes/push`:
|
|
32
|
-
```json
|
|
33
|
-
{ "filename": "<filename>", "content": "<full file content>", "sha": "<sha if updating>" }
|
|
34
|
-
```
|
|
35
|
-
5. On success, respond with: `Pushed → https://lab.dev.place.fund/proto/<filename>`
|
|
36
|
-
|
|
37
|
-
## Error handling
|
|
38
|
-
|
|
39
|
-
- 422 from push = filename invalid (wrong extension or path traversal attempt)
|
|
40
|
-
- 503 = credential service unavailable on the lab server
|
|
41
|
-
- 502 = GitHub API error — check if the file already exists and a `sha` is needed
|
|
42
|
-
|
|
43
|
-
## Notes
|
|
44
|
-
|
|
45
|
-
- This is the only way to get artifacts from claude.ai into the lab without copy-paste
|
|
46
|
-
- Git history in `apps/lab/docs/prototypes/` is the version store — every save is a commit
|