• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Any sh shell programmers here? I need some quick help.

TangDN

Member
Given a file name, how can I find out its absolute path , (within a script that is) ?
I can grab the filename (thats easy), I just don't know what the command is to get its absolute path name.

Thanks for the help! Its my first post! haha..😀
 
file=foo/bar/xyz.txt

abspath=$cwd/$file

Don't know how to get rid of any relative paths (../.. stuff) within the absolute path.
 
Back
Top