Skip to content

Instantly share code, notes, and snippets.

while [ 1 ]; do cp -R /tmp/PersonalizedRestoreBundle.* ~/Desktop/Pwnage/.; done
#!/usr/bin/env ruby
# ghetto gmail sms notification while I wait for GPush and when MsgPush fail
# Usage: ./gmail_sms_push.rb &
require 'net/imap'
require 'net/smtp'
domain = 'yourdomain.com'
from = "user@#{domain}"
username = 'username'
@ayn
ayn / snippet.txt
Created August 14, 2009 23:30
charset fail
CREATE TABLE `offerings` (
`id` int(11) NOT NULL auto_increment,
`course_id` int(11) default NULL,
`term_id` int(11) default NULL,
`sourcedId` varchar(255) NOT NULL,
`parent_sourcedId` varchar(255) NOT NULL,
`term_sourcedId` varchar(255) NOT NULL,
`department_sourcedId` varchar(255) default NULL,
`created_at` datetime default NULL,
`updated_at` datetime default NULL,
sqlite> .databases
seq name file
--- --------------- ----------------------------------------------------------
0 main /private/tmp/iPhotoMain.db
sqlite> .tables
AlbumsPhotosJoin SqFileImage SqPlace
GpsTracksEventsJoin SqFileInfo SqPlaceName
KeywordsPhotosJoin SqFilterAlbum SqPrintAlbum
MasterSchema SqGlobals SqPublishedAlbum
SqAlbum SqGpsTrack SqSlideshowAlbum
<div id="thumbs">
<ul class="thumbs noscript">
{% for photo in photos %}
<li>
<a class="thumb" href="{{ photo.url_large }}" title="{{ photo.title }}">
<img src="{{ photo.url_square }}" alt="{{ photo.title }}" />
</a>
<div class="caption">
<div class="flickr-link">
<a href="{{ photo.photopage_url }}" target="_blank" title="Go to Flickr page of this photo">Flickr link</a>
[ProBert:~] ayn% host api.del.icio.us
api.del.icio.us has address 208.69.36.130
api.del.icio.us is an alias for fe.api.del.vip.ac4.yahoo.net.
fe.api.del.vip.ac4.yahoo.net mail is handled by 0 .
[ProBert:~] ayn% host 208.69.36.130
130.36.69.208.in-addr.arpa domain name pointer hit-adult.opendns.com.
<!DOCTYPE FeedFlareUnit SYSTEM "FeedFlareUnit-1.0.dtd">
<FeedFlareUnit>
<Catalog>
<Title>Follow me</Title>
<Description>A static FeedFlare unit that goes to @ayn</Description>
</Catalog>
<FeedFlare>
<Text>follow @ayn on Twitter</Text>
<Link href="http://twitter.com/ayn"/>
</FeedFlare>
#pragma mark -
#pragma mark TTModel
- (BOOL)isLoading {
return !!_fakeLoadTimer;
}
- (BOOL)isLoaded {
return TRUE;
}
unless RAILS_ENV == 'test' || RAILS_ENV == 'cucumber'
require 'cache_money'
config = YAML.load(IO.read(File.join(RAILS_ROOT, "config", "memcached.yml")))[RAILS_ENV]
$memcache = MemCache.new(config)
$memcache.servers = config['servers']
$local = Cash::Local.new($memcache)
$lock = Cash::Lock.new($memcache)
$cache = Cash::Transactional.new($local, $lock)
{
"twitter_user": "amicel",
"title": "All methodologies are great, until you add people #agile #leanstartup",
"created_at": "2010-08-06 11:50:33",
"backtype_stats": {
"native": 0,
"external": 0,
"digg": 0,
"reddit": 0,
"twitter": 0,