[codex] add WebDAV-backed TP-7 mount#2
Open
totocaster wants to merge 1 commit into
Open
Conversation
Expose the TP-7 through macOS Finder without FUSE or system extensions by running a loopback WebDAV bridge over the existing long-lived MTP session.\n\nThe mount is read-only for now because safe Finder write support needs staged whole-file upload semantics over MTP.
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
Adds a first Finder-visible
tp7 mountimplementation without requiring macFUSE, Fuse-T, kernel extensions, system extensions, or FieldKit.The mount command now starts a loopback-only WebDAV bridge backed by a long-lived TP-7 MTP session, then asks macOS
mount_webdavto expose it as a Finder volume. With no mountpoint argument, it chooses/Volumes/TP-7, then/Volumes/TP-7 2, etc. A newtp7 unmountcommand tears down one mount when a mountpoint is provided, or all TP-7 mounts recorded by the CLI when no argument is passed.What Changed
tp7 mount [mountpoint]andtp7 unmount [mountpoint]command wiring.OPTIONS,PROPFIND,HEAD, andGET.tp7 unmountcan discover active CLI-owned mounts.Why
The goal is to expose the TP-7 filesystem as a folder/drive on macOS without shipping a filesystem extension. FieldKit can present a Finder-visible drive, but the CLI should stay independent of companion apps and avoid macFUSE/system-extension requirements. macOS' built-in WebDAV client gives us a native mount path that can be driven from a standalone Rust CLI.
Read-Write Boundary
This PR intentionally keeps the Finder mount read-only. MTP is object-based rather than block-based, so Finder/POSIX write behavior needs more than accepting
PUT: safe support requires staged whole-file writes, upload-on-close semantics, safe-save rename handling, delete/move mapping, metadata policy for.DS_Storeand AppleDouble files, and a decision for TP-7 folder creation behavior because firmware 1.1.9 rejected MTP folder creation in earlier hardware smokes.The
--read-writeflag exists only to fail clearly for now.Validation
Ran:
cargo fmt -- --checkcargo checkcargo clippy -- -D warningscargo testcargo run -- --helpcargo run -- mount --helpcargo run -- mount --read-writecargo run -- devicesHardware mount validation was not run because
cargo run -- devicesreported no TP-7 devices found on this machine at PR creation time.