LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-06-2002, 01:40 PM   #1
omgkthxbye
LQ Newbie
 
Registered: Oct 2002
Location: Waukesha, WI
Distribution: slack
Posts: 10

Rep: Reputation: 0
how do i remove a 'shortcut' directory?


first off, whats the proper nix term for a 'shortcut' directory? symlink er something?

anyway,

the detailed question is... i have 'mannual' directory in my /var/www/html (DocumentRoot for Apache) and I would like to remove it.

ls -l shows:

manual -> ../../../usr/share/doc/apache-manual-1.3.26/

and that to me, looks like it's a link to the real dir... how do i remove that "manual" dir and it's link?

thanks!
 
Old 11-06-2002, 01:42 PM   #2
omgkthxbye
LQ Newbie
 
Registered: Oct 2002
Location: Waukesha, WI
Distribution: slack
Posts: 10

Original Poster
Rep: Reputation: 0
HA!

# unlink manual

why is it that I ALWAYS find my answer right after I post sorry but hey, atleast it's here for others to find!
 
Old 11-07-2002, 07:26 AM   #3
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
Well I'm not sure how far you got on that but I think you got a few things mixed up. I'm not sure if I got everything right but as far as I know it's like this.

You can have hard links and symbolic links. Hard links only work on files and symbolic links can be done for both files and directories. You can create links with the following command 'ln sourcename targetname'. If you want it to be a symbolic link then you should add a -s to the ln command. You can't identify hard links by doing a ls -l. They just look like normal files although they physically all point to the same file. Once all links to the file are removed then the file itself is actually removed. If you do a ls -l for symbolic links then you will see the output like you showed:
targetname -> sourcename

You can remove symbolic links by just using the rm command. Now about the link and unlink commands. I don't have them on my linux system, I could however find them on a system with Digital Unix. But you can accomplish the same with ln and rm so they aren't really necessary.

Hope that helps.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
rm: cannot remove directory `ff': Directory not empty blancs Linux - General 17 08-29-2011 01:47 PM
Remove a Directory browser Linux - Newbie 8 08-11-2005 08:28 AM
how remove directory laurentwahl Linux - Newbie 1 05-31-2005 02:52 PM
home directory shortcut raaste Linux - Software 2 08-10-2004 01:08 PM
My Home directory shortcut folder on my desktop doesn't work Bensoft Kill MS Linux - Software 2 11-28-2003 09:31 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 11:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration