mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-04 14:46:03 +00:00
fix: handle non-existent initial directory in choose-files kitten (issue #10292)
This commit is contained in:
parent
7ed3477d5c
commit
7b3cbc1de3
1 changed files with 3 additions and 0 deletions
|
|
@ -982,6 +982,9 @@ func main(_ *cli.Command, opts *Options, args []string) (rc int, err error) {
|
|||
if default_cwd, err = filepath.Abs(default_cwd); err != nil {
|
||||
return
|
||||
}
|
||||
if st, serr := os.Stat(default_cwd); serr != nil || !st.IsDir() {
|
||||
default_cwd = utils.Expanduser("~")
|
||||
}
|
||||
|
||||
lp.OnInitialize = func() (string, error) {
|
||||
if opts.WritePidTo != "" {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue