> 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’.
Working with unix shell and no way you wont end up extracting file names from paths. Well there is a usual way to do it.
>basename /my/big/long/path/to/a/little/bitty/file file
Here is another way: