diff options
author | Robin Jarry <robin@jarry.cc> | 2023-08-23 21:36:23 +0200 |
---|---|---|
committer | Robin Jarry <robin@jarry.cc> | 2023-08-27 18:44:12 +0200 |
commit | a5bc7ccf0cae608ac1e72ab4c9ebe5596eb8c988 (patch) | |
tree | be2e5f55fc21980489dca61947ea6b9819853ec3 /worker/maildir/worker.go | |
parent | fff16640ad7cd8c4b73187fbce10f2aa558701be (diff) | |
download | aerc-a5bc7ccf0cae608ac1e72ab4c9ebe5596eb8c988.tar.gz |
xdg: get rid of deprecated dependencies
github.com/mitchellh/go-homedir has not received any update since 2019.
The last release of github.com/kyoh86/xdg was in 2020 and it has been
marked as deprecated by its author.
Replace these with internal functions.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Reviewed-by: Moritz Poldrack <moritz@poldrack.dev>
Diffstat (limited to 'worker/maildir/worker.go')
-rw-r--r-- | worker/maildir/worker.go | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/worker/maildir/worker.go b/worker/maildir/worker.go index e8da6fbd..de882589 100644 --- a/worker/maildir/worker.go +++ b/worker/maildir/worker.go @@ -18,11 +18,11 @@ import ( "time" "github.com/emersion/go-maildir" - "github.com/mitchellh/go-homedir" aercLib "git.sr.ht/~rjarry/aerc/lib" "git.sr.ht/~rjarry/aerc/lib/iterator" "git.sr.ht/~rjarry/aerc/lib/watchers" + "git.sr.ht/~rjarry/aerc/lib/xdg" "git.sr.ht/~rjarry/aerc/log" "git.sr.ht/~rjarry/aerc/models" "git.sr.ht/~rjarry/aerc/worker/handlers" @@ -361,10 +361,7 @@ func (w *Worker) handleConfigure(msg *types.Configure) error { w.worker.Debugf("configured base maildir: %s", dir) if name, ok := msg.Config.Params["folder-map"]; ok { - file, err := homedir.Expand(name) - if err != nil { - return err - } + file := xdg.ExpandHome(name) f, err := os.Open(file) if err != nil { return err |