Note to Self

MS Office Notes
Excel: To enter line breaks within a cell

option + ctrl + return

Excel: To edit a cell inline without leaving the keyboard

ctrl + u

Excel: To combine text from two different cells in one

=cell1& " " &cell2

produces

cell1 cell2

The key is in using the & sign at the end of the reference to first cell and the beginning of the reference to the second cell.

 

Mac OSX Notes
How to screen capture on your Mac

whole screen (makes 2 pictures for dual screen)

command + shift + 3

free hand

command + shift + 4

active window

command + shift + 4 + space bar

In OSX.3 (Panther), all screen capture files are saved as .tiff files.
In OSX.4 (Tiger), all screen capture files are saved as .png files.

How to zoom in & out of Mac OSX screen (must turn on Accessibility feature in Preferences pane)

command + option + 8

(“Apple, Option, Eight”) toggles Zoom on/off

command + option + =

(“Apple, Option, Equal Sign”) zooms in, centering on the cursor position when Zoom is on

command + option + -

(“Apple, Option, Minus Sign” ) zooms out

Negative Effect (must turn on Accessibility feature in Preferences pane)

command + option + ctl + 8

(“Apple, Option, Ctl, Eight” ) toggles the effect on/off

Hide HardwareGrowler from Dock

1. Right click on application -> Show Package Contents
2. Edit Info.plist in a text editor
3. Add the following

<key>LSUIElement</key>
<string>1</string>

4. In command line, type:

touch ~/path/to/HardwareGrowler.app

5. Relaunch application

Reset menu bar on Leopard Mac OS X

killall -HUP SystemUIServer

If SystemUIServer is not running, open terminal and run

/System/Library/CoreServices/SystemUIServer.app

Force bigger fonts on all incoming messages in Mail.app

defaults write com.apple.mail MinimumHTMLFontSize 13

Restart Cisco VPN daemon

sudo /System/Library/StartupItems/CiscoVPN/CiscoVPN restart

Restart the Mac OSX native VPN client

First see if the VPN client is already running:

If it is, something like this will show up:

root     36936   0.0  0.0  2435636   2040   ??  Ss    2:17PM   0:00.57 /usr/sbin/racoon -x

Kill it:

sudo killall racoon

or

sudo kill -9 <em>process id</em>

example using the grep result from above:

sudo -9 36936

Start it up again:

sudo /usr/sbin/racoon

 

Free BSD Notes
Post-install configuration interface:

/usr/sbin/sysinstall

updatedb in FreeBSD is:

/usr/libexec/locate.updatedb

Doh! It’s the same command in Mac OSX! (Duh… )

command to upgrade FreeBSD packages:

portupgrade package_name

Package management:

pkg_add (_check, _create, _delete, _info, _version) package_name

The command adds package from FreeBSD ports (kind of like apt-get for Debian or

emerge

for Gentoo)

To change the default startx to gnome:

1. Locate (or create) ~/.xinitrc
2. Add exec genome-session to the file
3.Save & exit
4. Logout and Login again

 

Debian Notes
ProFTPD: Local users without shell accounts cannot login

Issue /bin/false in /etc/shells file

ProFTPD: After the above is issued, local users cannot list directories

If iptables is being used:
As root, issue insmod ip_conntrack_ftp

To restart the IMAP server after a server reboot:

sudo /etc/init.d/dovecot restart

To change apache log permissions while rotating logs:

/etc/logrotate.d/apache (or whatever the log rotation script is called)
Modify the create 640 root adm line accordingly

To exit out of Text mode in Adobe Photoshop

While still in Text mode, press and hold Command key while pressing the return key

 

Cool “screen” Tips
http://www.bangmoney.org/presentations/screen.html
http://www.darkcoding.net/strategy/gnu-screen-basics-quick-reference/

 

Geeky Quotes:

To err is human… to really foul up requires the root password.

Unix is user-friendly. It’s just very selective about who its friends are.