Skip to content

Commit 113b412

Browse files
committed
feat: add cpToInstance and cpFromInstance functions
Add manually-maintained cp functionality to the SDK for copying files to/from running instances. This is placed in src/lib/ directory following the SDK's convention for custom extensions. Features: - cpToInstance: Copy local file/directory to instance - cpFromInstance: Copy file/directory from instance to local - WebSocket-based streaming with JSON control messages - Supports files and recursive directory operations - Handles symlinks, permissions, and modification times - Chunked binary data transfer for efficient streaming Adds ws as a peer dependency for WebSocket support.
1 parent 14bd119 commit 113b412

File tree

4 files changed

+1397
-2198
lines changed

4 files changed

+1397
-2198
lines changed

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,16 @@
2626
"lint": "./scripts/lint",
2727
"fix": "./scripts/format"
2828
},
29-
"dependencies": {},
29+
"dependencies": {
30+
"ws": "^8.18.3"
31+
},
3032
"devDependencies": {
3133
"@arethetypeswrong/cli": "^0.17.0",
3234
"@swc/core": "^1.3.102",
3335
"@swc/jest": "^0.2.29",
3436
"@types/jest": "^29.4.0",
3537
"@types/node": "^20.17.6",
38+
"@types/ws": "^8.18.1",
3639
"@typescript-eslint/eslint-plugin": "8.31.1",
3740
"@typescript-eslint/parser": "8.31.1",
3841
"eslint": "^9.39.1",

0 commit comments

Comments
 (0)