aboutsummaryrefslogtreecommitdiff
path: root/bash/bashrc.d/scp.bash
blob: 3d5fc1ddd8fcb749c00fe0ec6ddfcf2f8e4fce64 (plain) (blame)
1
2
3
4
5
6
7
8
9
# Wrap scp to check for missing colons
scp() {
    if (($# >= 2)) && [[ $* != *:* ]] ; then
        printf 'scp: Missing colon, probably an error\n' >&2
        return 1
    fi
    command scp "$@"
}