Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/docs/widgets.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ When looking at a directory, preview will show a file viewer much like MacOS' _F

The simplest way to view a new file is to double click its row in the file viewer. Alternatively, while the widget is focused, you can use the <Kbd k="ArrowUp" /> and <Kbd k="ArrowDown" /> arrow keys to select a row and press enter to preview the associated file.

##### Copy a File

If you have two directory widgets open, you can copy a file or a directory between them. To do this, simply drag the file or directory from one directory preview widget to another that is opened to where you would like it dropped. This even works for copying files and directories across connections.

##### View the Parent Directory

In the directory view, this is as simple as opening the `..` file as if it were a regular file. This can be done with the method above. You can also use the keyboard shortcut <Kbd k="Cmd:ArrowUp"/>.
Expand Down
68 changes: 66 additions & 2 deletions docs/docs/wsh-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -460,13 +460,77 @@ This allows setting various options in the `config/settings.json` file. It will

## file

The `file` command provides a set of subcommands for managing files across different storage systems, such as `wavefile`, `wsh` remote servers, and S3 (not yet supported).
The `file` command provides a set of subcommands for managing files across different storage systems, such as `wavefile`, `wsh` remote servers, and S3.

### ls
Copy link
Copy Markdown
Contributor

@esimkowitz esimkowitz Feb 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The commands are already documented below in this file


```sh
wsh file ls <file uri>
```

List files in a directory.

### cat

```sh
wsh file cat <file uri>
```

Display the contents of a file.

### info

```sh
wsh file info <file uri>
```

Show information about a file.

### rm

```sh
wsh file rm <file uri>
```

Remove a file.

### write

```sh
wsh file write <file uri>
```

Write stdin into a file, buffering input (10MB total file size limit).

### append

```sh
wsh file append <file uri>
```

Append stdin to a file, buffering input (10MB total file size limit).

### cp

```sh
wsh file cp <source file uri> <destination file uri>
```

Copy files between different storage systems.

### mv

```sh
wsh file mv <source file uri> <destination file uri>
```

Move files between different storage systems. The source file will be deleted once the operation completes successfully.

:::note

Wave Terminal is capable of managing files from remote SSH hosts, S3-compatible
systems, and the internal Wave filesystem. Files are addressed via URIs, which
vary depending on the storage system.
vary depending on the storage system. If no scheme is specified, the file will be treated as a local connection.

URI format: `[profile]:[uri-scheme]://[connection]/[path]`

Expand Down