Repository navigation
feat(tray): Total Commander style file manager (progress, cancel, gone-runtime banner); ls --json, mkdir, rm -r, --via ssh, --progress - #23
Merged
Conversation
The pieces the tray's file manager runs as CLI subcommands: - `colab ls --json`: one object with the path and its items (name, type, size, last_modified), folders first; an error is JSON too. - `colab mkdir PATH` creates a remote folder. - `colab rm -r PATH` removes a folder and everything in it (the contents API refuses a folder that is not empty), children first. - `colab upload/download --via ssh [-i KEY]` copies with OpenSSH scp through `colab ssh --proxy-mode` instead of the contents API; it uses the default key from `ssh_identity` / COLAB_CLI_SSH_IDENTITY. Tested live on an attached Colab web UI runtime: mkdir, a tree uploaded and downloaded back identical over scp, ls --json, rm -r. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Files button of a local card opens a Total Commander style window: this computer on the left (drive list, Up), the runtime on the right from /content. Drag and drop, the Upload/Download buttons or F5 copy between them; F7 makes a folder, F8 deletes (local files go to the recycle bin, remote ones after a confirmation), Enter or double-click opens, Backspace goes up. The line at the bottom runs a command in the runtime's folder: `colab ssh -- sh -c` over ssh, otherwise `colab exec` with Python on stdin, so it works without an SSH key. Transfers go over the contents API or ssh/scp, chosen at the top and saved as `tray_transfer` in settings.json. Every action is one of the CLI's own subcommands (ls --json, upload/download -r --via, mkdir, rm -r, ssh, exec), run one at a time with QProcess. Tested live: the window's runner uploaded, downloaded, ran a command and deleted on an attached Colab web UI runtime, and the window was tried from the tray (a locked system file reported its permission error). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ime is gone - Progress: a bar with files done / total, the file being copied and the time. `colab upload/download --progress` prints one line per file (ContentsClient.upload_dir/download_dir take an on_file hook); scp shows a moving bar and the time. - Cancel: stops the running command and drops the waiting ones. The whole process tree is stopped (taskkill /T on Windows, where scp would outlive the CLI; SIGTERM elsewhere, on which `--via ssh` kills scp). The output says what is left for each transfer mode. - When the runtime is gone (the tray's refresh no longer has it, or a command prints "Session not found"), a red banner says so, waiting commands are dropped and the remote side is disabled; the local pane keeps working, and the window comes back if the runtime does. - A failed or cancelled scp warns that the target may be cut short. - docs/09 section 5 documents the window in full; the README has user sections for the file manager and for runtimes from the Colab web UI. Tested live: per-file progress on a 30-file upload; cancel over the contents API (stopped at 7 of 60 files) and over scp (no scp.exe left); the banner after `colab stop` with the window open. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
|
Added after review: progress bar (files done / total via |
arlinamid
added a commit
that referenced
this pull request
Nov 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Tray: a two-pane file manager (Files button on a local card,
tray/files.py): this computer on the left (drive list, Up), the runtime on the right from/content.colab ssh -- sh -cover ssh, otherwisecolab execwith Python on stdin (no key needed).tray_transfer.tray/file_ops.pybuilds the argv).CLI pieces it runs:
colab ls --json(path + items with name/type/size/last_modified, folders first; errors as JSON),colab mkdir PATH,colab rm -r PATH(children first; the contents API refuses a non-empty folder),colab upload/download --via ssh [-i KEY](OpenSSH scp throughcolab ssh --proxy-mode, default key fromssh_identity).Tests
tests/test_files_extras.py,tests/test_tray_file_ops.py,tests/test_tray_files.py(offscreen Qt: listing, navigation incl. drives, F5, drag in both directions, F8 with/without confirmation, command line over ssh and exec, buttons, transfer setting). Full suite: 1374 passed.ls --json,rm -r; the window's real QProcess runner uploaded, downloaded, ran a command and deleted; the window was tried from the tray.🤖 Generated with Claude Code