[reddit]
domain: www.reddit.com
ssl_domain: ssl.reddit.com
user:
pswd:
until [[ -n `ping -c 1 69.54.26.116 | grep -o ttl.*time` ]] ; do
/etc/init.d/ipaliases restart
sleep 4
done
#!/sbin/runscript
depend() {
need bootmisc
after net
#!/bin/bash
# Get notifications of new reddit messages by email
MAIL="you@example.com"
# FROMMAIL = mail which will appear in the "from" header of the notifications
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain user;killall Finder;echo "Open With has been rebuilt, Finder will relaunch"
#!/usr/bin/perl
use strict;
use Mail::Mailer;
my $mailer = Mail::Mailer->new('smtp', Server => 'smtp.myserver.com');
#!/bin/bash
wget -erobots=off --no-parent --wait=3 --limit-rate=20K -r -p -U "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)" -A htm,html,css,js,json,gif,jpeg,jpg,bmp,png,woff http://pittas.me/envato/html/filoxenia/blue/index.html
#!bin/bash
rename .tar.gz -$(date +'%m%d%Y').tar.gz cpmove-*
<?php
/* From here: http://stackoverflow.com/questions/7671996/how-to-parse-user-mentions-in-php */
$text = 'say hello to @elise_123.com and @john-abc';
function replace_at_symbol($matches){
$username = str_replace("@", "", $matches[0]);
if ("$h_to:, $h_cc:, $h_bcc" contains "domain.com")
then
unseen deliver "dd@com.pl"
endif
if $sender_address: contains "domain.com"
<?php
/* This script could be used as a template when you need to convert a field value into something else. I used it when converting from MySQL DATATIME to Unix time as well as hashing out new passwords from old ones. */
include('config.php');
DELETE FROM `bb_posts` WHERE `bb_posts`.`post_status` = '2';
DELETE FROM `bb_posts` WHERE `bb_posts`.`post_status` = '1';
#!/bin/bash
#
# This will remove recent pictures which can be selected in Contacts, System Preferences, Messages as your avatar image
#
# Path to folder.
<?php
/* This will easily grab the result from a MySQL row instead of having to go through 3-4 lines of PHP code we can do it in about 2. I like this more. Need to implement across sites. */
$database_host = "";
$database_user = "";
<?php
$gitpull = exec('cd /home/git/git-repository ; /usr/local/bin/git pull origin');
if ($gitpull == "Already up-to-date.") {
echo "$gitpull - Up to date.";
exit();