Store relative accounts path in accounts.toml

This makes it possible to move accounts dir, especially useful for bots.
This commit is contained in:
link2xt
2022-12-12 18:54:30 +00:00
parent d1e3135331
commit 5922fb38da
3 changed files with 34 additions and 20 deletions

View File

@@ -14,9 +14,7 @@ class Rpc:
if accounts_dir:
kwargs["env"] = {
**kwargs.get("env", os.environ),
"DC_ACCOUNTS_PATH": os.path.abspath(
os.path.expanduser(str(accounts_dir))
),
"DC_ACCOUNTS_PATH": str(accounts_dir),
}
self._kwargs = kwargs