Commit Graph

32 Commits

Author SHA1 Message Date
Evan Simkowitz
b0e3b6d777
Fix move & copy for prefix filesystems (#1998)
Also makes recursive the default for copy, adds better error for move
without recursive
2025-02-20 10:17:32 -08:00
Evan Simkowitz
772ea41990
Clean up atom usage in preview (#1986) 2025-02-18 16:40:36 -08:00
Mike Sawka
da1f8dea38
s3 suggestions + widget cache (#1987) 2025-02-18 15:15:12 -08:00
Evan Simkowitz
3c75d1314c
Revert replacehomedir (#1976)
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>
2025-02-14 18:28:03 -08:00
Evan Simkowitz
71e126072e
Add S3 fileshare implementation, improve cp behavior (#1896)
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>
2025-02-14 17:27:02 -08:00
Mike Sawka
392fa508b1
new file typeahead control (#1913) 2025-02-06 18:02:16 -08:00
Evan Simkowitz
5339c9cc79
Fix WSH copy internal (#1906)
I was dumb and used `os.Rename` for copy on the same WSH remote. This
change makes it a proper copy, with recursion if needed.

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-02-05 19:12:00 -08:00
Evan Simkowitz
902ff9baf1
enable wsh file cross-remote copy/move (#1725)
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>
2025-01-31 10:42:39 -08:00
Mike Sawka
5418e5ad24
fail any rpc call which blocks the runServer loop for more than 1s (#1861) 2025-01-27 22:38:19 -08:00
Evan Simkowitz
965ed288f8
Remove fileshare logs (#1814) 2025-01-23 12:38:55 -08:00
Evan Simkowitz
9406967edd
Fix offset regression in wshremote (#1807)
Co-authored-by: sawka <mike@commandline.dev>
2025-01-22 22:24:35 -08:00
Evan Simkowitz
689b2d63c2
Revert my cheeky change (#1799) 2025-01-22 17:50:50 -08:00
Evan Simkowitz
a98242138d
Fix windows path for wsh url (#1798) 2025-01-22 17:28:59 -08:00
Evan Simkowitz
11fec5695c
wsh file overhaul without cross-remote copy and S3 (#1790) 2025-01-22 14:50:09 -08:00
Mike Sawka
9dc9066a81
conn updates 5 (#1755)
* token swap
* setting environment variables for different local/remote shells
* bug fixes for init scripts
* more logging
* update connserver startup flow
2025-01-16 11:17:29 -08:00
Sylvie Crowe
99e122d724
RcFileInstall RPC Command (#1720)
Creates an RPC command for installing shell rcfiles instead of relying
on a separate installation session.
2025-01-12 16:31:00 -08:00
Sylvie Crowe
0174e7cd07
RemoteInfo Rpc (#1719)
Adds an Rpc Command for getting RemoteInfo. This is used to replace the
session that was used to determine the shell on remote machines.
2025-01-12 15:22:07 -08:00
Evan Simkowitz
b51ff834b2
Happy new year! (#1684)
Update all 2024 references to 2025
2025-01-04 20:56:57 -08:00
Mike Sawka
904d942c4c
fix remote file stream function (#1620) 2024-12-26 10:23:28 -08:00
Evan Simkowitz
04c4f0a203
Create and rename files and dirs in dirpreview (#1156)
New context menu options are available in the directory preview to
create and rename files and directories

It's missing three pieces of functionality, none of which are a
regression:
- Editing or creating an entry does not update the focused index. Focus
index right now is pretty dumb, it doesn't factor in the column sorting
so if you change that, the selected item will change to whatever is now
at that index. We should update this so we use the actual file name to
determine which element to focus and let the table determine which index
to then highlight given the current sorting algo
- Open in native preview should not be an option on remote connections
with the exception of WSL, where it should resolve the file in the
Windows filesystem, rather than the WSL one
- We should catch CRUD errors in the dir preview and display a popup
2024-12-02 22:23:44 -08:00
Mike Sawka
7afd19f000
on windows, must close the new temp file before removing it (#1115)
Closes #1114
2024-10-24 09:46:52 -07:00
Sylvie Crowe
a5999aa02a
Plot Sysinfo (#1054)
Expands the cpuplot with memory plots and individual cpu plots. Also
improves the styling and handling of multiple plots.
2024-10-17 15:19:13 -07:00
Evan Simkowitz
ccf344d107
Fix path traversal vulnerabilities (#817)
Properly validate expanded paths to ensure they are not attempting path
traversal attacks
2024-09-24 18:24:39 -07:00
Mike Sawka
31414a7536
don't open files when stating directory (#797) 2024-09-20 12:25:46 -07:00
Evan Simkowitz
936d4bfb30
Migrate websocket eventbus messages to wps (#367)
This migrates all remaining eventbus events sent over the websocket to
use the wps interface. WPS is more flexible for registering events and
callbacks and provides support for more reliable unsubscribes and
resubscribes.
2024-09-11 18:03:55 -07:00
Mike Sawka
8ad84fd78a
update all gopkg imports (#330) 2024-09-05 14:25:45 -07:00
Mike Sawka
a7746bc5cc
fix rpc no-route errors, fix fileopen in preview (#313) 2024-09-03 21:08:51 -07:00
Mike Sawka
e3b7ab73c0
preview refactor for keyboard/focus (#303) 2024-09-02 16:48:10 -07:00
Mike Sawka
e488862355
remote sysinfo data plotting (#294) 2024-08-30 11:33:04 -07:00
Mike Sawka
0d8c159101
remote file preview (streaming) working (#248) 2024-08-19 14:37:52 -07:00
Mike Sawka
8651659c02
get remote preview working (#246)
almost all there -- just need to fix streamfile for web urls.
2024-08-19 11:02:40 -07:00
sawka
961502916b implement remotewritefile 2024-08-13 18:36:11 -07:00