man GhettoBSD
Over time, I’ll be adding some useful things in this section. All of it can be found by using man program. But this provides the most relevant information that I’m usually in need of.
I’ll start of with this:
## L
ln -s
This will create a symbolic link to a directory (it’s similar to a windows shortcut).
How to use:
- ln -s /dir/to/link/to /link/to/be/created
- ln -s /usr/ports/net-mgmt/snmp snmp
This will allow me to type: cd snmp instead of the full path. This is useful for many things.
Now, when you want to remove the symbolic link it can be a little tricky. If I type “rm snmp” I’ll get a warning that it’s a directory. So you might then try “rm -rf snp” and will be surprised when /usr/ports/net-mgmt/snmp has been deleted! So the correct way to remove a symbolic link is:
- rm /full/path/to/sym-link
So if you are in /home/user/directory1 and you have snmp symlink in that directory, you would type out “rm /home/user/directory1/snmp”