Browse Source

Add smart bcompare wrapper

In case of 2 parameters, the wrapper will short-circuit if the files are
same.
Alois Mahdal 10 years ago
parent
commit
c4da4cd715
1 changed files with 5 additions and 0 deletions
  1. 5
    0
      dotfiles/bash/main.bashrc

+ 5
- 0
dotfiles/bash/main.bashrc View File

@@ -21,6 +21,11 @@ clsz() {
21 21
     tput clear; tput cup $(tput lines) 0
22 22
 }
23 23
 
24
+bcdiff() {
25
+    test $# -eq 2 && diff "$@" >/dev/null && return
26
+    bcompare "$@" &
27
+}
28
+
24 29
 ### .... ###
25 30
 ### BASH ###
26 31
 ### '''' ###