List file with path from current working directory
I was looking for a command that could quickly locate a file within a newly mounted device, i.e. ... a dvd, or thumb drive. I could not find one so I wrote one. I placed it in my /bin directory.
I call it lsp ( List w/ Path ) if it finds the file it will list the path from the current working directory. Code:
#!/bin/bash Code:
$ lsp file-name Code:
$ cd /var/log |
Oh, and my list absolute path
Looking on the internet a lot more people seem to be looking for an absolute path.
lap ( List Absolute Path ) from the current working directory. Code:
#!/bin/bash |
Quote:
Code:
find . -type f -iname \*$1\* -printf "%h/%f\n" |
Thanks You, your command line works nicely too.
|
All times are GMT -5. The time now is 04:22 PM. |