Skip to content

Instantly share code, notes, and snippets.

View heygambo's full-sized avatar

Christian Gambardella heygambo

View GitHub Profile
@heygambo
heygambo / BitcasaFailedUploads-20131024T010200
Created October 24, 2013 05:45
Bitcasa still doesn't upload my files. They have been cached about 2 month now without any error notification. After I've uploaded some MB of data the Bitcasa client claims that it needs to upload 20gb of data. this is my iphoto library which should have been uploaded 2 month ago. What If I decided to delete my iPhoto Library from my Harddrive? …
This file has been truncated, but you can view the full file.
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2009/Zoo/P1000324.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2011/03/02/20110302-181927/188X5745.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2012/01/12/20120112-163037/IMG_0434.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2007/Marias Geburtstag/IMG_4479.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2008/Automatenfotos/Bodo, Jasper, Monika, Bodo.jpg
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2007/Fussballturnier/IMG_0030.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2010/Victor/IMG_9030.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2010/Fotos Ninos Einschulung/IMG_0260.JPG
/Volumes/Bitcasa Infinite Drive/Pictures/Pictures/iPhoto Library/Masters/2012/01/27/20120127-141939/P1000671.JPG
/Volumes/Bitcasa Infinite Drive/Pictu
@heygambo
heygambo / find_youtube_id.rb
Last active December 20, 2015 16:59
Find youtube id from any source in ruby (currently 4 types are supported)
def youtube_id(video_tag)
tests = []
tests.push(/embed\/([a-zA-Z0-9]+)/)
tests.push(/src="\/\/www.youtube.com\/v\/([a-zA-Z0-9]+)/)
tests.push(/youtu.be\/([a-zA-Z0-9]+)/)
tests.push(/youtube.com\/watch\?v=([a-zA-Z0-9]+)/)
tests.each do |regexp|
return video_tag.scan(regexp)[0][0] if video_tag.scan(regexp).length > 0
end
@heygambo
heygambo / custom.css
Last active December 15, 2015 18:09
kaiserberg immocommerce custom styles
a.button,
.button,
.property .contact .header,
body.welcome.index #scrollbar-track a,
body.welcome.index #coverTitle .property_code
{
background: #6ec93c; /* Old browsers */
background: -moz-linear-gradient(top, #6ec93c 0%, #58ac25 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#6ec93c), color-stop(100%,#58ac25)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #6ec93c 0%,#58ac25 100%); /* Chrome10+,Safari5.1+ */
@heygambo
heygambo / gist:4966826
Created February 16, 2013 12:51
How to use CoffeeKiq
# Creates an instance of CoffeeKiq
{CoffeeKiq} = require('coffeekiq')
coffeekiq = new CoffeeKiq "redis_port", "redis_host"
# Enqueues a Job to redis namespace: "" and retry: false
coffeekiq.perform 'queue', 'WorkerClass', ['arg1', 'arg2']
# Enqueues a Job to redis with namespace: "myapp:staging" and retry: true
coffeekiq.perform 'queue', 'WorkerClass', ['arg1', 'arg2'],
namespace: "myapp:staging"
@heygambo
heygambo / 01 get.yeoman.io script
Created September 13, 2012 20:31
bash: 'yeoman' command not found
○ → curl -L get.yeoman.io | bash
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 11625 100 11625 0 0 6714 0 0:00:01 0:00:01 --:--:-- 43867
Looks like you have the XCode CLI tools. Passed!
Installing on OS X.
You've got brew, nice work chap!
@heygambo
heygambo / brew-doctor
Created September 13, 2012 06:27
brew install git fails
===============
= brew doctor =
===============
Your system is raring to brew.
@heygambo
heygambo / install_ruby.sh
Created June 4, 2012 14:30
ruby installieren
#!/usr/bin/env bash
apt-get -y update
apt-get -y install build-essential zlib1g-dev libssl-dev libreadline5-dev libyaml-dev
cd /tmp
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p194.tar.gz
tar -xvzf ruby-1.9.3-p194.tar.gz
cd ruby-1.9.3-p125/
./configure --prefix=/usr/local
make
make install
@heygambo
heygambo / chef_solo_bootstrap.sh
Created June 4, 2012 09:33 — forked from ryanb/chef_solo_bootstrap.sh
Bootstrap Chef Solo
#!/usr/bin/env bash
apt-get -y update
apt-get -y install build-essential zlib1g-dev libssl-dev libreadline5-dev libyaml-dev
cd /tmp
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p125.tar.gz
tar -xvzf ruby-1.9.3-p125.tar.gz
cd ruby-1.9.3-p125/
./configure --prefix=/usr/local
make
make install
@heygambo
heygambo / gist:2001453
Created March 8, 2012 15:15
Remove All Gems
gem list | cut -d" " -f1 | xargs gem uninstall -aIx