Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

So I'm a dual-booter. I'm looking for an easy way to keep up-to-date symlinks in my Linux home folder pointing to every file and folder in the root of Windows personal directory.

So, say I have foo.txt and bar.txt in C:\Windows\Documents and Settings\Nathaniel. I want symlinks of those files to automatically be made in /home/nathaniel/ (while I'm running Linux, of course).

share|improve this question
    
Why not just make a symlink between the Nathaniel\Home directory and Users\Nathaniel directory (assuming your computer username for both OSs is your superuser username, obviously)? –  Daniel H Dec 31 '09 at 4:59
    
But this way the whole folder would show up as a symlink, if I read you right. It would show up as /home/nathaniel/nathaniel, wouldn't it? Not quite what I want. –  Nathaniel Dec 31 '09 at 6:12
    
No, it would just be /home/nathaniel, but if Ubuntu and Windows name the folders different things, it wouldn't work. –  Daniel H Jan 1 '10 at 0:28
    
Turns out putting your home directory on NTFS is a dangerous thing to do. Nice thing is I didn't try it, but found out first. See ubuntuforums.org/showthread.php?t=901127 . Guess I'll be sticking with the auto-symlink idea. –  Nathaniel Jan 4 '10 at 23:32

2 Answers 2

For a start, try adding to your .profile (or equivalent file run when you fire up your shell) something along the lines of:

# Mount the NTFS volume at `NTFS`, then...
WINHOME="NTFS/Windows/Documents and Settings/Nathaniel"
ln -s "$WINHOME"/* ~

You might want to consider what should happen if you have another file with that name already in ~; changing it to ln -sf might be good enough.

To keep the mirror current while you're logged in (e.g., to handle the case where you change WINHOME while running Linux), you could schedule that scrap of script to run regularly (using cron, for example), or employ some sort of directory watching daemon that you can use to discover when the directory contents change. (Under Mac OS X, I'd use launchd.)

share|improve this answer

In Windows, you can "move" the Documents, etc. folders. IDK how to do this in XP (if it's possible), but in Vista you just right-click on Documents, Desktop, Videos, etc. and say Properties, and then click Move... under the Location Tab. You can then make these the equivalents in your Ubuntu Home directory.

What Windows version do you have? I might be able to post specific instructions with screenshots.

share|improve this answer
    
Umm... not quite sure what you're driving at here. I'm just trying to create symlinks, not move my personal folder in my NTFS partition around. –  Nathaniel Dec 31 '09 at 6:08
    
If you move them around, they would all be connected. It would automatically read the same data both times. I think that Windows actually does create symlinks in this case. –  Daniel H Jan 1 '10 at 0:25

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.