From 75a4a592e5ccda30715f93563d741b83e0dcf39e Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Mon, 25 Apr 2011 13:37:00 +0000 Subject: Slackware 13.37 Mon Apr 25 13:37:00 UTC 2011 Slackware 13.37 x86_64 stable is released! Thanks to everyone who pitched in on this release: the Slackware team, the folks producing upstream code, and linuxquestions.org for providing a great forum for collaboration and testing. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. As always, thanks to the Slackware community for testing, suggestions, and feedback. :-) Have fun! --- slackbook/html/file-commands-link.html | 105 +++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 slackbook/html/file-commands-link.html (limited to 'slackbook/html/file-commands-link.html') diff --git a/slackbook/html/file-commands-link.html b/slackbook/html/file-commands-link.html new file mode 100644 index 000000000..8a3784fa7 --- /dev/null +++ b/slackbook/html/file-commands-link.html @@ -0,0 +1,105 @@ + + + + +Aliasing files with ln + + + + + + + + + + + +
+

10.7 Aliasing +files with ln

+ +

ln(1) is used to create links between files. These links can +be either hard links or soft (symbolic) links. The differences between the two kinds of +links were discussed in Section 9.3. If you +wanted to make a symbolic link to the directory /var/media/mp3 +and place the link in your home directory, you would do this:

+ + + + + +
+
+% ln -s /var/media/mp3 ~/mp3
+
+
+ +

The -s option tells ln to make a +symbolic link. The next option is the target of the link, and the final option is what to +call the link. In this case, it will just make a file called mp3 in your home directory that points to /var/media/mp3. You can call the link itself whatever you want by +just changing the last option.

+ +

Making a hard link is just as simple. All you have to do is leave off the -s option. Hard links may not normally refer to directories or span +file systems, however. To create a hard link /usr/bin/email to +/usr/bin/mutt, simply type the following:

+ + + + + +
+
+# ln /usr/bin/mutt /usr/bin/email
+
+
+
+ + + + + -- cgit v1.2.3