Skip to content

Commit e5b57a6

Browse files
committed
Add vault-pass script that uses bw and repo name
1 parent d8042dd commit e5b57a6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.vault-pass.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
# This script retrieves the password for the current git repository from a Bitwarden Vault.
3+
# If bw is not available, it should error out
4+
set -e
5+
bw get password "$(git remote get-url origin | awk '{split($0, a, "/"); print a[length(a)]}')"

0 commit comments

Comments
 (0)