This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# quick and dirty way to brute force palindromes in the gregorian calendar | |
# using the format MM/DD/YYYY | |
MAX=5000000000000 | |
i=0 | |
while [ $i -ne $MAX ] | |
do | |
i=$[$i+1] | |
MONTHZ=$(date +%m --date "-${i} days") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
RANDOMFILE="/tmp/${RANDOM}-${RANDOM}-${RANDOM}.txt" | |
RANDOMCONTENTS="${RANDOM}${RANDOM}${RANDOM}" | |
export $SUVVESS="3" | |
function writeit() | |
{ | |
touch $RANDOMFILE | |
echo -n $RANDOMCONTENTS > $RANDOMFILE | |
RETVAL=$? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
DICTFN="/usr/share/dict/words" | |
NUMBERZ="1 2 3 4 5 6" | |
NUMDICE=5 | |
WORDLIST="" | |
DICEARRAY="" | |
# TODO allow dynamic number of dice (up to a point, max size of dictfile) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Extracts all zipfiles in subdirectories to current directory. | |
for source in $(find . -name "*.zip") | |
do | |
unzip -tq $source | |
retval=$? | |
if [ $retval -eq 0 ] | |
then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ubuntu 12.04, assuming fresh install, still a work in progress | |
24 Feb 2013 | |
###### as root user | |
# install pre-reqs | |
apt-get update | |
apt-get -y upgrade | |
apt-get -y dist-upgrade | |
apt-get -y install gcc g++ make cmake unzip subversion git-core gzip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OPTIONS * RTSP/1.0 | |
CSeq: 1 | |
User-Agent: AudioStation/3.1 (Synology) | |
================================ | |
RTSP/1.0 200 OK | |
Audio-Jack-Status: connected; type=analog | |
CSeq: 1 | |
Public: ANNOUNCE, SETUP, RECORD, PAUSE, FLUSH, TEARDOWN, OPTIONS, GET_PARAMETER, SET_PARAMETER | |
================================ | |
ANNOUNCE rtsp://192.168.0.4/4166333301 RTSP/1.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# all as root | |
apt-get update | |
apt-get -y upgrade | |
apt-get -y install git libao-dev libssl-dev libcrypt-openssl-rsa-perl libio-socket-inet6-perl libwww-perl avahi-utils libmodule-build-perl | |
# Shairport pre-req | |
git clone https://github.com/njh/perl-net-sdp.git | |
cd perl-net-sdp | |
perl Build.PL | |
./Build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
gem 'daemons' | |
gem 'RubySunrise' | |
gem 'rufus-scheduler' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This is the case on Ubuntu | |
# TODO: Write checks for other OSes | |
which nc.traditional 1>&2> /dev/null | |
return_value=$? | |
if [ ${return_value} -ne 0 ]; then | |
echo "Traditional NC doesn't appear to be installed, please install 'netcat-traditional'" | |
exit 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
to getCurrentApp() | |
return (path to frontmost application as text) | |
end getCurrentApp | |
on processCheck() | |
tell application "System Events" to get name of every process | |
if the result contains "VIP Access" then | |
activate application "VIP Access" | |
else | |
processCheck() |
OlderNewer