Commit | Line | Data |
---|---|---|
0c0ef5c7 | 1 | #!/bin/sh |
2 | ||
3 | if [ $# -lt 1 ]; then | |
4 | echo "usage: btadd URL..." >&2 | |
5 | exit 1 | |
6 | fi | |
7 | ||
8 | for file in "$@"; do | |
9 | if [ -r "$file" ]; then | |
b88a238b | 10 | rsc pc17 btadd - <"$file" && rm -f "$file" |
0c0ef5c7 | 11 | elif [[ "$file" == http*://* ]]; then |
b88a238b | 12 | rsc pc17 btadd "$file" |
0c0ef5c7 | 13 | else |
14 | echo "rbtadd: $file: unreadable" >&2 | |
15 | fi | |
16 | done |