ssh_file_write
Write text files on a remote server atomically, replacing whole files with specified permissions, optional sudo, and sha256 verification. Supports multiple files in one call.
Instructions
Writes text files on a server, several in one call, each with its own permissions. Content lands under a temporary name and takes its place in one rename, so a half-written file never appears at the target, and an optional sha256 check confirms what arrived. A file is replaced whole; there is no append. For something that already exists on this machine, use ssh_upload.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| files | Yes | One file, or a list — mode and sudo decided per file, not per call. | |
| profile | Yes | Machine name. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| files | No | ||
| legend | No | What the words in this answer mean. A key names the field before the value — "state=limited", "jobs[].state=lost" — and only the values this answer actually used are listed. |