Fix GH #227: Force bd edit to always use direct mode
- bd edit now bypasses daemon to prevent broken pipe errors - Editing in /usr/local/bin/emacsclient can take minutes, causing daemon timeout - Added check in PersistentPreRun to set noDaemon=true for edit command - Human-only interactive command doesn't benefit from daemon anyway Fixes #227
This commit is contained in:
@@ -141,6 +141,12 @@ var rootCmd = &cobra.Command{
|
||||
noAutoImport = true
|
||||
}
|
||||
|
||||
// Force direct mode for human-only interactive commands
|
||||
// edit: can take minutes in $EDITOR, daemon connection times out (GH #227)
|
||||
if cmd.Name() == "edit" {
|
||||
noDaemon = true
|
||||
}
|
||||
|
||||
// Set auto-flush based on flag (invert no-auto-flush)
|
||||
autoFlushEnabled = !noAutoFlush
|
||||
|
||||
|
||||
Reference in New Issue
Block a user