diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2015-04-16 16:39:51 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2015-04-16 16:39:51 +1200 |
commit | 36c783f71f4b44f479f7f6d74cdce67731102908 (patch) | |
tree | 4598e3722ad7d851bb16b61ed7917ece7a09dd81 /bash | |
parent | histverify for safety (diff) | |
download | dotfiles-36c783f71f4b44f479f7f6d74cdce67731102908.tar.gz dotfiles-36c783f71f4b44f479f7f6d74cdce67731102908.zip |
Whoops, didn't mean to delete it
Diffstat (limited to 'bash')
-rw-r--r-- | bash/bashrc.d/scp.bash | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/bash/bashrc.d/scp.bash b/bash/bashrc.d/scp.bash new file mode 100644 index 00000000..3d5fc1dd --- /dev/null +++ b/bash/bashrc.d/scp.bash @@ -0,0 +1,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 "$@" +} + |