From e705d5d7358e42a35dba8994f0ea4c445e4f0c81 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Tue, 2 Apr 2013 03:33:59 +0200 Subject: [PATCH] shell/aliases: Add aliases mv (mv -i) and cp (cp -i -a). --- shell/aliases.in | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/shell/aliases.in b/shell/aliases.in index 27ce92c..023ed60 100644 --- a/shell/aliases.in +++ b/shell/aliases.in @@ -29,6 +29,15 @@ alias s=mpc # s for sound, m is already used alias v=vim +# Ask for confirmation before overwriting files. Especially useful when moving +# to a different directory. No alias for `rm` because I specify the files to +# remove directly, so I know what will happen. +alias mv='mv -i' +# Additionally preserve all file attributes when copying, this includes +# copying symbolic links as is without dereferencing them. +alias cp='cp -i -a' + + # Make sure there is no alias named ls as it causes problems with the # following ls function on (at least) bash 4.0.35. unalias ls 2> /dev/null -- 2.44.1