teamclaws 2.0.17 → 2.0.19
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/dist/constants.js +1 -1
- package/package.json +1 -1
- package/skills/teamclaws-project/SKILL.md +57 -15
package/dist/constants.js
CHANGED
package/package.json
CHANGED
|
@@ -61,18 +61,50 @@ teamclaws shell <server-id> --command <one-quoted-command-argument> --json
|
|
|
61
61
|
This sends the exact command over the authenticated workspace HTTPS shell API.
|
|
62
62
|
Check `pwd`, `printf '%s\n' "$HOME"`, and `id` rather than assuming the starting
|
|
63
63
|
directory is the user's home. Use explicit working directories in commands.
|
|
64
|
-
The result has `stdout`, `stderr`, and `exit_code`.
|
|
65
|
-
|
|
64
|
+
The result has `stdout`, `stderr`, and `exit_code`. Inspect the output and status
|
|
65
|
+
for the operation performed; do not treat every nonzero status as a stop condition.
|
|
66
|
+
Verify file transfers against the destination bytes. There is no dedicated CLI file-transfer command and no
|
|
66
67
|
implicit SSH connection. Do not invent one or handle the saved credential yourself.
|
|
67
68
|
|
|
69
|
+
### Default destination for shared documents
|
|
70
|
+
|
|
71
|
+
Default shared documents, reports, findings, and transfers to the provisioned
|
|
72
|
+
`handoffs` directory unless the user names another destination. Keep projects in
|
|
73
|
+
their selected directories; do not change the general working directory or move them.
|
|
74
|
+
|
|
75
|
+
Discover the exact shared path through the existing paired shell:
|
|
76
|
+
|
|
77
|
+
```text
|
|
78
|
+
teamclaws shell <server-id> --command 'printf "%s\n" "$TEAMCLAWS_HANDOFFS_DIR"' --json
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Use the returned absolute path, not `$HOME`, the starting directory, or a guessed
|
|
82
|
+
temporary location. If the advertised path is absent or unavailable on an older
|
|
83
|
+
workspace, report that it needs the sharing update. Do not create an unshared
|
|
84
|
+
fallback or claim shared delivery; continue authorized reads and other searches.
|
|
85
|
+
|
|
86
|
+
Keep secrets, credentials, browser profiles, and unrelated private files out.
|
|
87
|
+
Create fresh destination bytes using the directory's provisioned group/default
|
|
88
|
+
ACLs; do not move private files in or preserve their `0600` mode. Default ACLs
|
|
89
|
+
handle a restrictive umask, but explicit private modes can still deny collaborators.
|
|
90
|
+
For a shared document you own, retain the inherited group and enable group
|
|
91
|
+
read/write on that file. Do not change other identities' or parent permissions.
|
|
92
|
+
|
|
93
|
+
Record the exact path, matching source/destination SHA-256 hashes, and whether
|
|
94
|
+
the intended recipient can read the actual file through normal authorized access.
|
|
95
|
+
The writer's own read does not establish recipient access. If recipient access is
|
|
96
|
+
unverified, report that accurately and continue other authorized work.
|
|
97
|
+
|
|
68
98
|
### Find a file the user left on the server
|
|
69
99
|
|
|
70
100
|
When the user names a file without a path, explain where they probably put it
|
|
71
101
|
when working through the CLI, then inspect those locations before asking them
|
|
72
102
|
for a full path:
|
|
73
103
|
|
|
104
|
+
- The advertised `TEAMCLAWS_HANDOFFS_DIR` and its children first for shared
|
|
105
|
+
documents and handoffs. Discover it using the command above.
|
|
74
106
|
- The directory reported by `pwd`, and the project's directory if known.
|
|
75
|
-
- `/tmp/`, especially an existing `/tmp/
|
|
107
|
+
- `/tmp/`, especially an existing `/tmp/handoffs/` handoff directory,
|
|
76
108
|
and `/var/tmp/`. These are temporary locations, not durable storage.
|
|
77
109
|
- The shared workspace, commonly `/home/teamclaws_user/`, including documented
|
|
78
110
|
project, artifact, or handoff directories in `LOCAL_AGENT.md` or project instructions.
|
|
@@ -87,8 +119,12 @@ Do not change permissions or switch identities to search inaccessible locations.
|
|
|
87
119
|
Search the named directory and its children for the exact filename first;
|
|
88
120
|
use a case-insensitive or partial-name search if needed. Prefer `rg --files
|
|
89
121
|
--hidden --no-ignore -g '<filename>' <directory>` when available; otherwise use
|
|
90
|
-
`find <directory> -iname '<filename>' -print`.
|
|
91
|
-
|
|
122
|
+
`find <directory> -iname '<filename>' -print`. A search can return matches and a
|
|
123
|
+
nonzero status when one child directory is unreadable. Keep those matches and
|
|
124
|
+
continue searching every other readable directory; report inaccessible branches
|
|
125
|
+
separately. Do not use `set -e` or `&&` to abort independent searches on such errors.
|
|
126
|
+
Do not suppress permission errors or turn an incomplete search into a claim that
|
|
127
|
+
the file does not exist. Check
|
|
92
128
|
directory symlinks explicitly without following them outside the authorized scope.
|
|
93
129
|
|
|
94
130
|
If the file is still unfound, report the actual searched locations and access
|
|
@@ -97,29 +133,35 @@ a found non-secret file, return its bytes through the paired shell (base64 is
|
|
|
97
133
|
suitable), save them locally, and compare the remote and saved SHA-256 hashes.
|
|
98
134
|
Preserve the remote original and do not print encoded file contents unnecessarily.
|
|
99
135
|
|
|
100
|
-
For
|
|
101
|
-
base64-encoded
|
|
102
|
-
files. Construct the argument with a subprocess argument
|
|
103
|
-
interpolation). A remote Python example for a single
|
|
136
|
+
For shared documents, write into the advertised handoffs directory. For a project,
|
|
137
|
+
use its selected destination. Decode base64-encoded bytes there and compare SHA-256
|
|
138
|
+
hashes against the local files. Construct the argument with a subprocess argument
|
|
139
|
+
list (no local shell interpolation). A remote Python example for a single shared
|
|
140
|
+
**non-secret** document is:
|
|
104
141
|
|
|
105
142
|
```text
|
|
106
143
|
python3 - <<'TEAMCLAWS_FILE'
|
|
107
|
-
import base64, hashlib, pathlib
|
|
108
|
-
|
|
109
|
-
p
|
|
144
|
+
import base64, hashlib, os, pathlib
|
|
145
|
+
handoffs = pathlib.Path(os.environ['TEAMCLAWS_HANDOFFS_DIR'])
|
|
146
|
+
p = handoffs / 'README.md'
|
|
110
147
|
with p.open('xb') as output:
|
|
111
148
|
output.write(base64.b64decode('SGVsbG8K', validate=True))
|
|
149
|
+
p.chmod(0o660)
|
|
112
150
|
print(hashlib.sha256(p.read_bytes()).hexdigest())
|
|
113
151
|
TEAMCLAWS_FILE
|
|
114
152
|
```
|
|
115
153
|
|
|
116
154
|
Replace the path and encoded content from the selected project; the example
|
|
117
155
|
writes the bytes `Hello\n`. Exclusive creation prevents overwriting existing
|
|
118
|
-
files.
|
|
156
|
+
files. The directory must already be provisioned; the example does not create it.
|
|
157
|
+
The file inherits its collaboration group and ACLs, and `0660` keeps group
|
|
158
|
+
read/write without granting other users access. Check remote Python availability
|
|
159
|
+
before using this example, then verify the intended recipient's read access. Transfer
|
|
119
160
|
larger files in bounded chunks to a new staging file, checking the final hash.
|
|
120
161
|
Use project-appropriate consistent exports for databases and persistent data;
|
|
121
|
-
copying an active database file is not a verified backup. Preserve file
|
|
122
|
-
where needed;
|
|
162
|
+
copying an active database file is not a verified backup. Preserve project file
|
|
163
|
+
modes where needed; use the handoff sharing permissions for shared documents.
|
|
164
|
+
Inspect symlinks and never follow them outside the selected source.
|
|
123
165
|
If an archive is used, reject absolute paths, parent traversal and escaping links
|
|
124
166
|
before extraction. Verify the destination file inventory and hashes, then place
|
|
125
167
|
it at the agreed destination without overwriting unrelated data.
|