Skip to content

Commit 63db415

Browse files
committed
rename attach to store
1 parent 51e45f3 commit 63db415

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

file.bash

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
#!/bin/bash
22

33
print_usage() {
4-
echo "Usage: $PROGRAM file attach|retrieve pass-name [path]"
5-
echo " Attach or retrieve file to/from password store."
4+
echo "Usage: $PROGRAM file action pass-name [path]"
5+
echo "Actions:"
6+
echo " store|add|attach: add new file to password store"
7+
echo " retrieve|show|cat: retrieve file from password store and print it to stdout"
68
exit 0
79
}
810

9-
cmd_attach() {
11+
cmd_store() {
1012
local path="$1.b64"
1113
local file="$2"
1214
local passfile="$PREFIX/$path.gpg"
@@ -49,8 +51,8 @@ cmd_retrieve() {
4951
}
5052

5153
case $1 in
52-
attach|add)
53-
shift && cmd_attach "$@"
54+
store|add|attach)
55+
shift && cmd_store "$@"
5456
;;
5557
retrieve|show|cat)
5658
shift && cmd_retrieve "$@"

0 commit comments

Comments
 (0)