diff options
| author | alex <alex@pdp7.net> | 2023-10-17 22:35:29 +0200 |
|---|---|---|
| committer | alex <alex@pdp7.net> | 2023-10-17 22:35:29 +0200 |
| commit | ea7726c3df7540972eb803d1f190cd484e8a2f86 (patch) | |
| tree | 54a8d67fdb993166291758e7302d951080d38507 /scripts | |
| parent | 83229b45e273ee659cd0e300650e549b66ed0aee (diff) | |
Add sync
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/p7s/bitwarden.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/p7s/bitwarden.py b/scripts/p7s/bitwarden.py index 9ce4d44c..f3f26dd1 100644 --- a/scripts/p7s/bitwarden.py +++ b/scripts/p7s/bitwarden.py @@ -47,6 +47,9 @@ class Bitwarden(): finally: del os.environ["BW_SESSION"] + def sync(self): + subprocess.run([self.bw_command, "sync"], check=True) + def status(self): return json.loads(subprocess.run([self.bw_command, "status"], check=True, stdout=subprocess.PIPE).stdout) @@ -58,4 +61,5 @@ def get_item(server, email, uuid): b = Bitwarden() b.download() with b.login(server, email): + b.sync() return b.get_item(uuid) |
