Create a directory path as below under /root : India_ADID Karnataka_ADID Tamilnadu_ADID Kerala_ADID Bangalore_ADID Chennai_ADID Munnar_ADID Now, do the following tasks(using Relative Path) - a) Change to your home directory. Create an empty file called place_2_see_ADID in Munnar_ADID. b) Copy that file to India_ADID. c) Change the name of the file you copied in India_ADID as very_good_place_ADID. d) Go to Chennai_ADID directory, list the content of the directory called India_ADID from there. e) Being at Chennai_ADID directory, delete the place_2_see_ADID file. f) Remaining at Chennai_ADID directory, remove Bangalore_ADID directory.
Answers
Answer:
We now know how to explore files and directories, but how do we create them in the first place?
Step one: see where we are and what we already have
Let’s go back to our data-shell directory on the Desktop and use ls -F to see what it contains:
$ pwd
/Users/nelle/Desktop/data-shell
$ ls -F
creatures/ data/ molecules/ north-pacific-gyre/ notes.txt pizza.cfg solar.pdf writing/
Create a directory
Let’s create a new directory called thesis using the command mkdir thesis (which has no output):
$ mkdir thesis
As you might guess from its name, mkdir means ‘make directory’. Since thesis is a relative path (i.e., does not have a leading slash, like /what/ever/thesis), the new directory is created in the current working directory:
$ ls -F
creatures/ data/ molecules/ north-pacific-gyre/ notes.txt pizza.cfg solar.pdf thesis/ writing/