You are not logged in.
Pages: 1
I've just put my whole home folder into a subversion repo (actually two), so almost whenver I'm doing something, it's inside a working copy. Is there some way to set up Bash so that when I'm in those working directories, it aliases the normal file commands (mv cp etc) to their svn counterparts? But when I'm not in a working copy, it automatically reverts back to the normal commands?
The Bytebaker -- Computer science is not a science and it's not about computers
Check out my open source software at Github
Offline
You'd probably want to craft some functions - something like:
function cp-svn-version()
{
if [ "$(pwd | cut -d'/' -f1-2)" = "/home/myusername" ]; then
svn cp $@
else
cp $@
fi
}
Then do alias cp="cp-svn-version", and so on.
Offline
Pages: 1