diff options
| author | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-07-24 16:07:14 +0200 |
|---|---|---|
| committer | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-07-24 16:07:14 +0200 |
| commit | 0321ea57f5c561215a8dea111ed7f3ea7b05594e (patch) | |
| tree | 75ce332f8985907fcd0118aa2c3f4aafb8587ad7 /internal/bookmarks/bookmarks.go | |
| parent | f48b79d8860e4c4616821ceeeea091ab4b838197 (diff) | |
| download | lectio-0321ea57f5c561215a8dea111ed7f3ea7b05594e.tar.gz lectio-0321ea57f5c561215a8dea111ed7f3ea7b05594e.zip | |
tui reader: bookmarks (m=mark w/ note, b=list/jump/delete, per-verse via top-visible verse) + remember last place; v0.18.0
Diffstat (limited to 'internal/bookmarks/bookmarks.go')
| -rw-r--r-- | internal/bookmarks/bookmarks.go | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/internal/bookmarks/bookmarks.go b/internal/bookmarks/bookmarks.go index ac8926d..55a9e55 100644 --- a/internal/bookmarks/bookmarks.go +++ b/internal/bookmarks/bookmarks.go @@ -35,15 +35,7 @@ type Store struct { // bookmarks.json, mirroring the sigla store) and returns a ready Store. It never // fails: a missing file simply reads as an empty list. func Open() *Store { - base := os.Getenv("XDG_DATA_HOME") - if base == "" { - home, err := os.UserHomeDir() - if err != nil { - home = "." - } - base = filepath.Join(home, ".local", "share") - } - return &Store{path: filepath.Join(base, "lectio", "bookmarks.json")} + return &Store{path: dataFile("bookmarks.json")} } // ParseTags splits a comma-separated tag string into trimmed, non-empty tags. |
