diff options
Diffstat (limited to 'tools/abspath')
-rwxr-xr-x | tools/abspath | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/abspath b/tools/abspath new file mode 100755 index 0000000000..a2d1410b9b --- /dev/null +++ b/tools/abspath @@ -0,0 +1,9 @@ +#!/bin/sh +# +# print the absolute path of each argument + +for relpath in $* ; do + D=`dirname "$relpath"` + B=`basename "$relpath"` + echo "`cd \"$D\" 2>/dev/null && pwd || echo \"$D\"`/$B" +done
\ No newline at end of file |