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.

Is there a feature on OS X that does the same as mklink under Windows 7? It can create symbolic links and hard links.

I have just read about this tool to have Dropbox sync an application folder by combining it with mklink on Windows 7, using a hard link:

http://www.hackingfreaks.in/2011/01/9-amazing-software-mashups-killer-free.html

How can I achieve this on OS X?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

Open /Applications/Utilities/Terminal.app and run ln for a short description, and man ln for documentation.

Example:

ln existing.txt new.txt

For folders, create a symbolic link using ln -s:

ln -s existing new

As per @Scott's comment, these symbolic links work with Dropbox on OS X. Success!


Hardlinks on folders are possible, but difficult and insanely dangerous if you mess it up (they don't like recursion).

share|improve this answer
    
I don't know either, but the Windows example uses hard links, not symbolic links. OS X supports hard linked folders since Time Machine has been introduced. Never used it myself though. –  Arjan Jan 11 '11 at 16:48
    
@Arjan Thanks for the edit to the question, I just saw it and added to my reply. –  Daniel Beck Jan 11 '11 at 16:49
2  
Use a symlink to sync folders outside your Dropbox on Mac OS X (and Linux for that matter). It works fine, and you avoid the whole can of worms that hard linking directories is. See wiki.dropbox.com/TipsAndTricks/SyncOtherFolders –  Scott Jan 11 '11 at 16:59
    
@Scott Thanks, updated –  Daniel Beck Jan 11 '11 at 17:00
    
Thanks guys, that's exactly what I was looking for! –  Cilvic Jan 12 '11 at 7:50

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.