1

Possible Duplicate:
bash/fish command to print absolute path to a file

Say I'm in a directory /usr/temp/foo, which has a file named bar.txt

How do I get the fullpath of bar.txt? (which should be /usr/tem/foo/bar.txt)

Community
  • 1
  • 1
user1508893
  • 9,223
  • 14
  • 45
  • 57

1 Answers1

2

Try:

readlink -f bar.txt

Extra text to make SO happy.

Jeremy J Starcher
  • 23,369
  • 6
  • 54
  • 74