Uh oh!
There was an error while loading. Please reload this page.
Fixed prview rendering in tpm script - #21
Open
Mohammadhoseinajorloo wants to merge 7 commits into
Open
Conversation
after chenging name 'tmux project manager' to 'project manager' should chenging alias until work command in zsh Ref: #14
This file collection of tmux managment command. Ref: #14
Management and handel restor session tmux in start tmux server. Ref: #14
Handel UI/UX for working with project manager. Ref: #14
- Delete previw part from ui file in lib folde - Add `tmux-session-preview` script for rendering preview in fzf - Update `project-manger` script for read preview script Ref: #7
Closed
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 freeto 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.
Description:
Overview
This PR refactors the session preview mechanism in the Tmux Project Manager (
tpm). It moves the embedded inline preview logic out ofui.shinto a standalone, testable script (tmux-session-preview) and adds session existence validation to eliminate race conditions and broken preview errors.Problem
fzflist generation and preview rendering,tmuxthrew stderr errors (e.g.,can't find session: 'session-name').ui.shsuffered from fragile shell quoting issues when passed throughfzf --preview.Changes Made
scripts/tmux-session-previewto handle preview generation independently.tmux has-session -t "$session"upfront; displays a clean dimmed message (Session is no longer available.) if the target session does not exist instead of leaking raw tmux errors.activeindicators), and captured pane output (-S -30with ANSI colors).lib/project_manager/ui.sh):generate_preview_cmdbash-string interpolation.select_project_fzfto accept the preview script path as an argument, keepingfzfinvocation clean and robust against shell escaping bugs.scripts/project-manager):PREVIEW_SCRIPTpath directly toselect_project_fzf.How to Test
Direct Preview Test:
Interactive TUI Test:
./scripts/project-manager.Ctrl+Dand ensure the preview transitions cleanly without tmux error traces.Checklist
fzfselection menu.scripts/tmux-session-preview(chmod +x).