Repository navigation
refactor(config): group media output under tmp/media, scoped to the open project - #1486
Merged
Merged
Conversation
…pen project Generated and retained media now share one media root with a subdirectory per kind: sfx, video, music, tts, voice, recordings, screenshots and attachments (Telegram photos and videos, formerly the flat tmp/media). The root follows the open project. While the CLI runs in a project it is ~/.infer/projects/<slug>/tmp/media, so a project selected in the desktop app keeps its media to itself. It falls back to ~/.infer/tmp/media when the cwd is $HOME or the desktop's ~/.infer/workspace. config.MediaDir resolves the root for every default. Explicit output_dir, recordings_dir, media.dir and screenshot.temp_dir overrides still win. Both roots were already sandbox carve-outs and are wiped by /reset.
2 tasks done
Contributor
|
🎉 This PR is included in version 0.223.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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
Generated and retained media now share one media root with a subdirectory per kind.
~/.infer/tmp/sfx<root>/sfx~/.infer/tmp/video<root>/video~/.infer/tmp/music<root>/music~/.infer/tmp/tts<root>/tts~/.infer/tmp/voice<root>/voice~/.infer/tmp/recordings<root>/recordings~/.infer/tmp/media(flat)<root>/attachments~/.infer/projects/<slug>/tmp/screenshots<root>/screenshotsThe root follows the open project. While the CLI runs in a project it is
~/.infer/projects/<slug>/tmp/media, so a project selected in the desktop app keeps its media to itself. It falls back to~/.infer/tmp/mediawhen the cwd is$HOMEor the desktop's~/.infer/workspace.config.MediaDir(kind)resolves the root for every default. Explicitoutput_dir,recordings_dir,media.dirandscreenshot.temp_diroverrides still win.RuntimeArtifactDirNames/UserspaceRuntimeDirNames) and are wiped by/reset, so neither changes.saveScreenshothelper now./resetclears them.Cross-repo impact
backend/tauri.conf.jsonscopes assets to$HOME/.infer/tmp/**and$HOME/**/.infer/tmp/**, andsafeImageSrcinfrontend/lib/tools.tsonly matches.infer/(tmp|artifacts|avatars)/. Media from a selected project now lands under$HOME/.infer/projects/*/tmp/media/**, so TTS playback, video and screenshot previews need that path added to both. Tracked in [FEATURE] Preview and play media from the per-project media root desktop#378.cli.md(userspace tmp tree table, computer_use recording, music, sfx, video and tts rows),cli-text-to-speech.md,cli-text-to-video.mdanddesktop.md(asset-scope caveat) need the new layout. Tracked in [DOCS] Document the per-project media root for generated and retained media docs#910.Test plan
TestMediaDirtable test covers an open project,$HOMEand~/.infer/workspacego test ./...task precommit:run