feat(grw): drive domain - #20
Merged
Merged
Conversation
Adds grw drive upload/mkdir/rename/move/trash/restore/delete on top of the shared read command tree, backed by internal/rw/drive. delete defaults to Trash and gates --permanent behind the typed confirmation or --yes, like mail delete; bulk IDs come from args, --stdin, or --query. Closes #8
3 tasks
rianjs
added a commit
that referenced
this pull request
Sep 3, 2026
* feat(grw): mail send <draft-id> (#19) * feat(grw): mail send <draft-id> Adds the product's only send path: grw mail send fetches a draft's headers, previews them, and sends via drafts.send from internal/rw/gmail. Dry-run stops after the preview; drafts with no recipients are refused. gro still links no send code, enforced by the architecture tests. Closes #9 * fix(mail): make the send preview trustworthy Fetch drafts in full format so attachments are visible, skip inline parts when counting them, refuse recipient-less drafts in dry-run too, and note that Gmail sends the draft as it exists at send time. * docs: state when write leaves need confirmation * feat(grw): drive domain (#20) Adds grw drive upload/mkdir/rename/move/trash/restore/delete on top of the shared read command tree, backed by internal/rw/drive. delete defaults to Trash and gates --permanent behind the typed confirmation or --yes, like mail delete; bulk IDs come from args, --stdin, or --query. Closes #8 * fix(drive): sanitize printed file names and explain the client and trash quirks
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.
Summary
internal/rw/drive:UploadFile(MIME from extension, falling back to content sniffing),CreateFolder,RenameFile,MoveFile(swaps all current parents),TrashFiles/UntrashFiles(ForceSendFieldsfor the false case),DeleteFilesPermanently. Every call passesSupportsAllDrives(true).internal/rwcmd/drive:upload,mkdir,rename,move,trash,restore,delete. Bulk leaves take positional IDs,--stdin, or--querythroughinternal/bulk;deletedefaults to Trash and gates--permanentbehind the same typed confirmation /--yesasmail delete. Every leaf has--dry-run/-n.drive(full) alongside the existing readonly and metadata scopes so the per-service read coverage test holds. Architecture tests cover the new pair; README, WORKSPACE_ADMINS, and architecture docs updated.Stacks on
feat/grw-write-surfaces. Closes #8Test plan
make check,make test-cover-check(75.3%),go test ./internal/architecture/grw drive upload go.mod --dry-runprints path/size/MIME/parent and exits 0 without a client;gro drive --helpunchanged