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
# Create Encrypted Volume | |
user=`echo $USER` | |
echo "Creating $HOME/encrypted_volume..." | |
dd if=/dev/zero of=$HOME/encrypted_volume bs=1M count=1024 | |
losetup /dev/loop0 $HOME/encrypted_volume | |
losetup -a | |
cryptsetup -y create enc_home /dev/loop0 | |
cryptsetup status homes | |
mkfs.ext4 /dev/mapper/enc_home | |
mkdir $HOME/encrypted |
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
#!/usr/bin/ruby | |
require 'mysql' | |
begin | |
puts "Dumping mysql databases..." | |
system("rm -f /root/mysql/*") | |
mysql = Mysql.real_connect('localhost','root','password','mysql') |
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 | |
convert_dir=$1 | |
output_dir=$2 | |
bitrate=$3 | |
# Ensure require params are passed in | |
if [ -z $convert_dir ] || [ -z $output_dir ]; | |
then | |
echo "Usage: flac2mp3 rip_dir output_dir [bitrate]" | |
exit |
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
#!/usr/bin/env lua | |
local http = require("socket.http") | |
local zip_code = "60614" | |
-- Grab google weather data | |
url = "http://www.google.com/ig/api?weather=" .. zip_code | |
data = http.request(url) | |
-- Only snag current conditions | |
current = data:match("<current_conditions>(.-)</current_conditions>") |
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
function PurgeQuestLog() | |
print("Purging Quest Log...") | |
numEntries, numQuests = GetNumQuestLogEntries() | |
for i=1,numEntries do | |
questTitle, level, questTag, suggestedGroup, isHeader, isCollapsed, isComplete, isDaily, questID = GetQuestLogTitle(i); | |
if not isHeader then | |
print("Abandoning: " .. questTitle) | |
SelectQuestLogEntry(i) | |
SetAbandonQuest() | |
AbandonQuest() |
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
-- Config | |
local onlyAnnounceMine = false | |
local enabled = true | |
local whisperTargets = true | |
-- Environment Setup | |
local frame = CreateFrame("Frame", nil, UIParent); | |
local players = {} | |
-- Should Announce Check |
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
local function SearchForSpellID(msg, editbox) | |
if not msg or msg:len() == 0 then | |
print("Usage: /wtfux Spell Name") | |
return | |
end | |
if GetSpellLink(msg) then | |
print("Spell ID: " .. GetSpellLink(msg):match("spell:(%d+)")) | |
else | |
print("Your character can not cast " .. msg) |
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
-- General Options | |
local inviteRanks = { "Prodigy", "Pedagogue", "Abecedarian", "Lab Rat", "Genius"} | |
local inviteLevel = 85 | |
local autoConvertRaid = true | |
-- Loot Threshold | |
-- 0. Poor (gray): Broken I.W.I.N. Button | |
-- 1. Common (white): Archmage Vargoth's Staff | |
-- 2. Uncommon (green): X-52 Rocket Helmet | |
-- 3. Rare / Superior (blue): Onyxia Scale Cloak |
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
$user = new User; | |
$user->name = 'foo'; | |
$user->save; |
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 | |
# | |
# Automatically run phpunit when you save a test | |
# | |
# Requires: inotify-tools | |
# | |
################### | |
path=$1 | |
orig_dir=`pwd` |
OlderNewer