Link to home
Start Free TrialLog in
Avatar of ahchong
ahchong

asked on

Long Directory Name

Hello, currently I am using Window 98 and Redhat Linux 6.1. I got a problem, that is: I mount my hda1 (windows partition) and "use" it from linux. Seem that I can't access to windows c:\program files (because of blank between program and files !!), What should I do if I want to access into this directory ???
ASKER CERTIFIED SOLUTION
Avatar of R_Walsdorf
R_Walsdorf

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of DVB
DVB

Lets say your windows partition is mounted on /win. Then cd "/win/program files" to cd to that directory. Else try using auto completion, just press the tab key to complete the filename.
Do:$cd /w <TAB>
Get:$cd /win
Do:$cd /win/pr <TAB>
Get:$cd "/win1/program files"
This works.
The "easy way" is to use the format that MICROS~1 themselves have pioneered - take the first 6 letters of the directory, then add ~1

The only time this sometimes has problems is when you have multiple directories with the same 1st 6 characters (usually in Program Files when you have lots of MS apps installed - you'll see MICROS~1,~2,~3,~4, etc.)

However, for the typical stuff, just something like :

cd /dosmnt/Progra~1

will do the trick for you.

Ian
ibishop: the short aliases are not available when the partition is mounted as 'vfat', you would have to mount it as 'msdos'.
Huh, my answer went missing??
Anyways, to repeat:
Use quotes
Assume that thw windows partition s mounted on /win.
cd "/win/Program files/"
I would recommend that you use auto completion, by just pressing the tab key.
Type in the minimum number of characters to uniquely identify the file, and press the tab key. It autoinserts quotes where necessary.
Ignore the second post. That will teach me not to use kfm!!