First, follow the installation guide at Andy Hunt's Blog
In addition to Andy's guide above, perform the following steps:
#!/bin/sh | |
# get / set volume | |
volume() { | |
if [ -z $1 ]; then | |
local volume=`osascript -e 'output volume of (get volume settings)'` | |
local muted=`osascript -e 'output muted of (get volume settings)'` | |
echo $volume $muted | |
else | |
osascript -e 'set volume output volume '$1 |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Disabled</key> | |
<false/> | |
<key>Label</key> | |
<string>org.apache.tomcat</string> | |
<key>ServiceDescription</key> | |
<string>Tomcat Servlet/JSP Server</string> |
#!/bin/sh | |
# Batch Auto Suspender for Twilio Sub Accounts | |
# Copyright (C) 2013 Jeroen Wesbeek <work AT osx.eu> | |
##################### USAGE ####################### | |
# | |
# Run the script command line or using a cron job: | |
# ~ $ ./TwilioAutoSuspend.sh | |
# | |
# To try out your patterns and whitelist, use the | |
# -p (pretent) argument. This will only output to |
# spindown after 1 minute of inactivity | |
sudo pmset -a disksleep 1 | |
# disable spotlight indexing and searching | |
sudo mdutil -d /Volumes/Your_Secondary_Harddrive |
# Twilio Commands | |
# put this in your ~/.profile | |
TWILIO_MASTER_SID=put here your master SID | |
TWILIO_MASTER_TOKEN=put here your master token | |
TWILIO_BASE_URL=https://api.twilio.com/2010-04-01/ | |
TWILIO_CREDENTIALS=$TWILIO_MASTER_SID":"$TWILIO_MASTER_TOKEN | |
twilio() { | |
if [ ! "$1" ]; then | |
echo "Usage:" | |
echo "------" |
#!/bin/sh | |
# usage: | |
# m h dom mon dow command | |
# * */4 * * * ~/scripts/updatePiratebayProxy > /dev/null | |
# Configuration | |
HOSTNAME=tpb.example.com | |
REPO_BASE=~ | |
DESTINATION=/etc/apache2/sites-available/example.com_tpb.conf | |
ACCESS_LOG=/var/log/apache2/example.com_tpb-access.log |
#!/bin/sh | |
NOW=`date +"%s"` | |
NEXT_FRIDAY=`date -v+fri +"%m%d"` | |
FRIDAY_5PM=`date -j $NEXT_FRIDAY"1700" +"%s"` | |
SECONDS_LEFT=$[$FRIDAY_5PM - $NOW] | |
DAY_OF_THE_WEEK=`date +"%u"` | |
# is it weekend yet? | |
if [[ ( $SECONDS_LEFT -lt 0 || $DAY_OF_THE_WEEK > 5 ) ]]; then | |
# yes! It's weekend |
First, follow the installation guide at Andy Hunt's Blog
In addition to Andy's guide above, perform the following steps:
GNU Screen is a virtual console multiplexer, and it has long been available on Mac. However, it was developed with login names of 20 characters or less in mind. Nowadays it is possible that login names actually exceed the 20 character limit (for example when using Active Directory), resulting in Screen quiting with the nice error message LoginName too long - sorry and rendering Screen useless on these Macs.
Below are the steps to download, patch and compile screen yourself to allow login names of up to 255 characters.
$ cvs -z3 -d:pserver:[email protected]:/sources/screen co screen
$ cd screen/src
$ curl "https://raw.github.com/pclouds/pclouds-overlay/master/app-misc/screen/files/4.0.3-extend-d_termname-ng2.patch"|patch
$ for x in Makefile.in config.h.in configure process.c pty.c screen.cc windows.c; do
curl "http://www.opensource.apple.com/source/screen/screen-16/patches/${x}.diff?txt" | patch
######################### | |
# .gitignore file for Xcode4 / OS X Source projects | |
# | |
# NB: if you are storing "built" products, this WILL NOT WORK, | |
# and you should use a different .gitignore (or none at all) | |
# This file is for SOURCE projects, where there are many extra | |
# files that we want to exclude | |
# | |
# For updates, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects | |
######################### |