I often found the Unix command ln confusing. It just seems kind of back to front to me.
Here for my reference and anyone else, is how to use it.
$ ln -sv <existing_folder> <new_link_name>
-s to create a symbolic link
-v for verbose output
How to Reverse the mouse scroll direction in windows
TL;DR – Run regedit as an admin, search for “FlipFlopWheel” and replace the 0’s with 1’s, unplug and reinsert the mouse.
- Open Control Panel, double click “Mouse” to open the mouse properties windows, and then click on the “Hardware” tab.
- Select your mouse in the list of devices then click on the properties button in the bottom right corner, just above the “Apply” and “Help” buttons.
- In the device properties dialogue window, click on the “Details” tab and then select “Hardwire Ids” from the “Property” drop-down list. You should see a list of entries starting with “HID…”. Write down the values that start with “HIDVID_???…”.
- Close device properties by clicking “Cancel”.
- Close “Mouse Properties” by clicking “Cancel”.
- Find and open the application “regedt32.exe” as an administrator, if you are not already logged in as one.
- Navigate to “HKEY_LOCAL_MACHINESYSTEMCurrentControlSetEnumHID”, and look for an entry that resembles the “VID_???…” number that you wrote down earlier in step 3.
- Open each sub entry under your specified “VID_???…” key, and open the “Device Parameters” key.
- There should be a key named “FlipFlopWheel” under each of the “Device Parameters” key. Reverse the entry value for the “FlipFlopWheel”. i.e. if default is “0” (zero) change it to “1”, and vice-versa.
- Do the same step 9, for each alphanumeric text string key entry, and their “Device Parameters”, “FlipFlopWheel”.
- Close “regedt32.exe”.
- Unplug your USB mouse, wait for 5 to 10 seconds, then plug the mouse back in again. If that doesn’t work then reboot.
By default the Library folder in your home folder is hidden, who knows why.
To unhide it, use the following commands.
1. Go to Finder.
2. Click on Go.
3. Click on Utilities.
4. Open Terminal.
chflags nohidden ~/Library
6. Press Return.
7. Go to the Library folder.
Setting the hostname on your Mac using scuttle
- Open a terminal.
- Type the following command to change the primary hostname of your Mac:
sudo scutil –set HostName <new host name>
- Type the following command to change the Bonjour hostname of your Mac:
sudo scutil –set LocalHostName <new host name>
- Optional: If you also want to change the computer name, type the following command:
sudo scutil –set ComputerName <new name>
sudo scutil --get HostName
sudo scutil --get LocalHostName
sudo scutil --get ComputerName
How to automount an SMB share in Mac OS X
- Connect to your network share, in Finder, Select Go, then Connect to server
- Enter the credentials for your login to your network drive and tick the ‘remember in keychain’
- Open system settings, select users and groups then click on login items
- Drag the icon for your network drive from your desktop to the startup items.