mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-05-13 08:26:56 +00:00
kitten @: Fix relative paths for --password-file being resolved relative to CWD instead of the kitty config directory
This commit is contained in:
parent
dadd2b88de
commit
10273d5aa2
2 changed files with 7 additions and 0 deletions
|
|
@ -202,6 +202,9 @@ Detailed list of changes
|
|||
|
||||
- icat kitten: When catting multiple images display the images in input order (:iss:`9413`)
|
||||
|
||||
- kitten @: Fix relative paths for --password-file being resolved relative to
|
||||
CWD instead of the kitty config directory
|
||||
|
||||
|
||||
0.45.0 [2025-12-24]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ import (
|
|||
"fmt"
|
||||
"io"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
|
@ -339,6 +340,9 @@ func get_password(password string, password_file string, password_env string, us
|
|||
}
|
||||
} else {
|
||||
var q []byte
|
||||
if !filepath.IsAbs(password_file) {
|
||||
password_file = filepath.Join(utils.ConfigDir(), password_file)
|
||||
}
|
||||
q, err = os.ReadFile(password_file)
|
||||
if err == nil {
|
||||
ans.is_set, ans.val = true, strings.TrimRight(string(q), " \n\t")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue