Archive for February, 2012
> lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 11.10 Release: 11.10 Codename: oneiric
Some people are really a big fan of ‘vim’ and so they also use ‘vimdiff’ over the default ‘diff’ utility. ‘vimdiff’ shows you a side by side diff which is very easy to read (shown in the image below).
Now if you are using ‘git’ and you run ‘git diff’ you will get a diff which is not very human readable. Thats where ‘vimdiff’ comes.
> git diff diff --git a/todo-java-app/pom.xml b/todo-java-app/pom.xml index 96aebba..6b9af3f 100644 --- a/todo-java-app/pom.xml +++ b/todo-java-app/pom.xml @@ -1,5 +1,6 @@ +testing 4.0.0 com.rokoder todo-java-app @@ -48,4 +49,4 @@ 5.1.18 - \ No newline at end of file + > >
‘git’ supports ‘vimdiff’ as a diff tool. Run the below command to change the diff tool to ‘vimdiff’.
Here is the test data that we gonna use:
>grep create *.log 1.log:create1 1.log:create2 10.log:create1 10.log:create2 2.log:create1 2.log:create2 3.log:create1 3.log:create2 4.log:create1 4.log:create2 5.log:create1 5.log:create2 6.log:create1 6.log:create2 7.log:create1 7.log:create2 8.log:create1 8.log:create2 9.log:create1 9.log:create2 >
Finding the First N matches