Results 1 to 2 of 2
Hi,
I am having difficulty in getting this right. What I am trying to do is to make a copy of a particular file in a folder in ubuntu 10.04.
...
- 01-20-2011 #1Just Joined!
- Join Date
- Nov 2005
- Posts
- 9
question on file path on terminal
Hi,
I am having difficulty in getting this right. What I am trying to do is to make a copy of a particular file in a folder in ubuntu 10.04.
For example,
I want to make a copy of a file called configuration.php. On the terminal, I was at that directory already. My question is instead of typing in the whole path again, I am looking for an easier way without having to type the directory path (games directory under etc) but still does the copying
Any help would be greatly appreciated
Thank you
- 01-20-2011 #2Linux User
- Join Date
- Jan 2005
- Location
- Saint Paul, MN
- Posts
- 262
First learn about tab completion. Second learn about using ~-/. Third, when you are in the directory containing the file, you do not need the path on the source. Fourth, if you are in the destination directory, then the path does not need to be on the destination filename (similar to item three). Fifth learn about the '..' path meaning up one directory level (hint ../../../ would move up three directory levels (do if you were at /home/userfred/abc/def/ghi/jkl and you referenced the file ../../../bcd/efg then it would be /home/userfred/bcd/efg)
Means in the directory that I was in just before cding into this one.Code:~-/filename
TAB COMPLETION
When entering a path hit the tab key it will type the remainder of the path (or stop at a place where a choice needs to be made). If a choice needs to be made enter the next character if known or hit the tab key again to see the choices. Entering the needed character (or characters) to make it unique and hit the tab key again. Repeat as needed to specify the path (good when typing in bash).


Reply With Quote
