Skip to content

Instantly share code, notes, and snippets.

View xiplias's full-sized avatar

Anders Hansen xiplias

  • Copenhagen, Denmark
View GitHub Profile
@ttscoff
ttscoff / itunesicon.rb
Last active January 13, 2022 10:07
Retrieve a 512 x 512px icon for an iOS app
#!/usr/bin/ruby
# encoding: utf-8
#
# Updated 2017-10-25:
# - Defaults to large size (512)
# - If ImageMagick is installed:
# - rounds the corners (copped from @bradjasper, https://github.com/bradjasper/Download-iTunes-Icon/blob/master/itunesicon.rb)
# - replace original with rounded version, converting to png if necessary
#
# Retrieve an iOS app icon at the highest available resolution
(function(global) {
var silpUrl = '//s3-eu-west-1.amazonaws.com/silp.shootitlive.com/js/silp.min.js';
// Globals
if(!global.Silp) { global.Silp = {}; };
var Silp = global.Silp;
// To keep track of which embeds we have already processed
if(!Silp.foundEls) Silp.foundEls = [];
@watson
watson / unblock.rb
Created October 3, 2011 07:59
Use this shell-script to change your DNS servers to the European Unblock-US servers via one simple command. Requires the 'open4' gem.
#!/usr/bin/env ruby
begin
require 'rubygems' if RUBY_VERSION =~ /^1\.8/
require 'open4'
rescue LoadError
puts "Please install the `open4` gem"
exit 1
end
@betamatt
betamatt / faye.rb
Created April 10, 2011 20:23
Faye monit wrapper
#!/usr/env ruby
base_dir = File.expand_path("../..", __FILE__)
NAME="faye"
PID="#{base_dir}/tmp/pids/#{NAME}.pid"
COMMAND="bundle exec rackup -s thin -E production -p 3001 faye.ru"
case ARGV[0]
when "start"
@jacortinas
jacortinas / description
Created February 21, 2011 22:30
watchr configuration
Gems:
gem 'cucumber'
gem 'cucumber-rails'
gem 'rspec'
gem 'rspec-rails'
gem 'capybara'
gem 'database_cleaner'
gem 'spork'
gem 'watchr'
@rodreegez
rodreegez / rails_tested.md
Created May 6, 2010 15:24
Hudson, Ruby Enterprise Edition, Nginx.

Testing Rails with Hudson CI

Written for Ubuntu LTS 10.4

Update and upgrade

  $ sudo aptitude update
  $ sudo aptitude upgrade