Adds the S3 `fileshare` implementation
This also updates `wsh file cp` so it behaves more like `cp` for things
like copying directories and directory entries. It's not meant to align
with `cp` on everything, though. Our `wsh cp` will be recursive and will
create intermediate directories by default.
This also adds new aliases for `wsh view`: `wsh preview` and `wsh open`
---------
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: sawka <mike@commandline.dev>
Co-authored-by: Sylvia Crowe <software@oneirocosm.com>
A bug prevented the final row from being removed while searching for
directory files. Additionally, a console error would come up when the
directory was filtered far enough. This corrects a react dependency so
that is no longer an issue.
A recent refactor introduced the BlockRegistry to add different types of
widgets. This was missing the tips widget, so it has been added to
correct that.
This change makes it so changes to the presets file are no longer being
written to metadata. Instead, the preset data is read separately
(although it is still possible to override it with metadata if done
manually).
Because presets are being tracked separately, if the associated metadata
key is not set, changes to the `presets/ai.json` file will be applied
immediately without switching the preset choice. Note that `ai:preset`
is still used in metadata to associate a block with a preset.
Additionallly, this introduces a database migration to clear out the
metadata items starting with `ai:` except for `ai:preset`. This will
allow the change to apply to existing blocks in addition to new ones.
If a file drag and drop file fails because the file already exists, this
adds a popup to allow the operation to be retried with the overwrite
flag set. Additionally, it will make a similar dismissible popup to
cover other copy errors.
Let's you drag and drop to copy files between preview widgets, even if
they use different connections.
---------
Co-authored-by: Evan Simkowitz <esimkowitz@users.noreply.github.com>
👋 Hello, I'm not sure if this warranted an Issue first but it seemed
small enough to just raise a PR. I'm happy to add something to the
documentation as well if you agree with the proposal.
There are some widgets that I'd rather not be displayed in the sidebar -
at the moment these are default widgets for which I cannot see any
existing means of omitting them via configuration. I'm proposing a
`display:hidden` field on the widget settings such that I can configure
the following:
```json
{
"defwidget@ai": {
"display:hidden": true
}
}
```
I'm considering this option to be distinct from any means of outright
"disabling" the widget - that is to say that I've not chosen to filter
the widgets from the configuration because I'm not fully aware of the
project goals. Where for example I imagine that it might be useful to be
able to interact with a widget or it's config via the CLI or shortcut
regardless of visibility?
<img width="1421" alt="example"
src="https://github.com/user-attachments/assets/7cafa942-727d-4140-8940-38b4022f2ef0"
/>
Adds schema.json support to the settings file to provide type hints and
other eventual details. This also adds a system to easily add more
schema files for other type of configurations.
The web widget already had a zoom feature, but the help widget did not.
This change ports the zoom feature so it is available on the help widget
as well.
There was a recent backend change that update the interface to
FileDeleteCommand. This updated was not reflected in
directorypreview.tsx on the frontend. This updates the frontend to
match.
This changes the .pem mimetype to application/x-pem-file. It also
changes the .pub mimetype to text/plain. Lastly, it updates
textApplicationMimetypes with this change.
This adds the ability to stream `tar` archives over channels between
`wsh` instances. The main use cases for this are remote copy and move
operations.
It also completes the `wavefs` implementation of the FileShare interface
to allow copy/move interoperability between wavefiles and other storage
types.
The tar streaming functionality has been broken out into the new
`tarcopy` package for easy reuse.
New `fileshare` functions are added for `CopyInternal`, which allows
copying files internal to a filesystem to bypass the expensive interop
layer, and `MoveInternal`, which does the same for moving a file within
a filesystem. Copying between remotes is now handled by `CopyRemote`,
which accepts the source `FileShareClient` as a parameter. `wsh`
connections use the same implementation for `CopyInternal` and
`CopyRemote` as they need to request the channel on the remote
destination, since we don't offer a way to pass channels as a parameter
to a remote call.
This also adds a recursive `-r` flag to `wsh file rm` to allow for
deleting a directory and all its contents.
S3 support will be addressed in a future PR.
---------
Co-authored-by: sawka <mike@commandline.dev>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>