Skip to main content

Posts

Showing posts from March, 2017

How to Open a File in Vim Editor without Navigating through all the nested Directories

                      O ne day I was working on something and I needed to modify the configuration file on the server. So I had to navigate to all the way through nested directories and then finally edit the file. The requirement was quite frequent and every time I had to navigate to multiple directories. This post is about to simplify the above task. For example, We need to edit the following file. File path : /home/alex/Softwares/apache-tomcat-7.0.62/webapps/live-service/WEB-INF/classes/conf/database/database.conf We can do it by using the below command: alex:~$ vim /home/alex/Softwares/apache-tomcat-7.0.62/webapps/live-service/WEB-INF/classes/conf/database/database.conf If we count the nested directories, There are 10 directories We need to navigate through and It is cumbersome even we know the exact path of the file. We will try to do something which can reduce the effort of navigating to nested directories. eg. The below command will work as above vim command. alex:~$