Absolute and Relative Paths?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Absolute and Relative Paths?
# 1  
Old 10-05-2009
Absolute and Relative Paths?

Can someone cofirm that I have got the paths correct here? Smilie

$PATH_TO_TMP_DIR='/tmp';
#$PATH_TO_TMP_DIR='home/tmp';

$PATH_TO_YOUR_IMG_DIR = '/temp_images';
#$PATH_TO_YOUR_IMG_DIR = 'home/public_html/Midwich/temp_images';

Thanks
# 2  
Old 10-05-2009
Hi.

I'm not sure what the question is.

Are the paths correct for what?

As per the subject, I can only say that the paths are absolute. The commented paths (starting with #) are relative.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Convert Relative path to Absolute path, without changing directory to the file location.

Hello, I am creating a file with all the source folders included in my git branch, when i grep for the used source, i found source included as relative path instead of absolute path, how can convert relative path to absolute path without changing directory to that folder and using readlink -f ? ... (4 Replies)
Discussion started by: Sekhar419
4 Replies

2. Shell Programming and Scripting

Show only the filenames under a directory without relative and absolute paths.

I am able to list all the filenames under a directory & its sub-directories except blent.tar on Linux find "/tmp/" -type f | grep -v blent.tar | rev | cut -d '/' -f1 | rev Desired Output: THIRDPARTYLICENSEREADME.txt javaws libjavaplugin_oji.so libjavaplugin_oji.so... (3 Replies)
Discussion started by: mohtashims
3 Replies

3. Shell Programming and Scripting

Remove leading dot and slash on relative paths with find

When I specify a directory by name the leading ./ is not shown: $ find somedir/ somedir/a.bin somedir/target/out.binBut when I specify current dir it adds the ./ to the beginning of each result: $ find . | grep somedir ./somedir/a.bin ./somedir/target/out.binIs there any particular reason why... (2 Replies)
Discussion started by: Tribe
2 Replies

4. Solaris

exclude absolute paths when extracting Tar file?

Hi, How do I extract data from TAR excluding absolute paths for Tar? (Solaris) Thanks (3 Replies)
Discussion started by: zam
3 Replies

5. Shell Programming and Scripting

tar and relative paths

HOw can I create a tar file with relative paths find . -depth -print | xargs tar -cvf /tmp/file.tar ? Thanks to all who answer (1 Reply)
Discussion started by: BeefStu
1 Replies

6. Shell Programming and Scripting

how to remove absolute paths from zip archive

Hi, I need to write an bash script which works like it can copy files from remote machine through ssh to the server where script is running in zip format with the structure i want. I don't want to get absolute path in zip archive. Please let me know how it can be possible. ssh... (4 Replies)
Discussion started by: mirfan
4 Replies

7. UNIX for Dummies Questions & Answers

tar symlinks: relative vs absolute

I create the tar file from / like so: tar cEhf name.tar usr/us And this creates the tar with the links intact. The problem is that this tar is going to be used for testing, so we want the links to point to the files in the tar. But when I extract the tar into /tmp, I get /tmp/usr/us/... as I... (2 Replies)
Discussion started by: TreeMan
2 Replies

8. UNIX for Dummies Questions & Answers

get cygpath to leave relative paths as relative?

If I execute mypath=`cygpath -w ../` echo $mypath I get d:\unix\nextVersion\script OK, d:\unix\nextVersion\script is the correct windows version of the path, but it is in absolute form. I would prefer it if cygpath left it in relative form, i.e. echo $mypath should output ..\ ... (0 Replies)
Discussion started by: fabulous2
0 Replies

9. Shell Programming and Scripting

expanding dotted paths to absolute ones in bash or sh

I have a little script to help me manage a gallery of image files. It makes symbolic links to every file in and below the current directory, placing them in a target directory which is passed to the script as a parameter. Unfortunately, the script pukes when I pass a parameter that contains... (4 Replies)
Discussion started by: TanRanger
4 Replies

10. Shell Programming and Scripting

Relative directory - NOT absolute

Here is the drill, I am using a script to login to a remote ftp, and put and get files. My question is: I want to login and automatically change to the same directory I am in on my machine. I can not use $home, pwd or anyother env variable (that I know) since the names of the machines are totally... (4 Replies)
Discussion started by: sierra_aar
4 Replies
Login or Register to Ask a Question