We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 51e45f3 commit 63db415Copy full SHA for 63db415
file.bash
@@ -1,12 +1,14 @@
1
#!/bin/bash
2
3
print_usage() {
4
- echo "Usage: $PROGRAM file attach|retrieve pass-name [path]"
5
- echo " Attach or retrieve file to/from password store."
+ echo "Usage: $PROGRAM file action pass-name [path]"
+ 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"
8
exit 0
9
}
10
-cmd_attach() {
11
+cmd_store() {
12
local path="$1.b64"
13
local file="$2"
14
local passfile="$PREFIX/$path.gpg"
@@ -49,8 +51,8 @@ cmd_retrieve() {
49
51
50
52
53
case $1 in
- attach|add)
- shift && cmd_attach "$@"
54
+ store|add|attach)
55
+ shift && cmd_store "$@"
56
;;
57
retrieve|show|cat)
58
shift && cmd_retrieve "$@"
0 commit comments