Skip to content

Instantly share code, notes, and snippets.

View remino's full-sized avatar

Rem remino

View GitHub Profile
@remino
remino / line.svg
Created March 7, 2014 07:02
LINE Icon SVG File
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@remino
remino / mixi.svg
Created March 7, 2014 07:06
Mixi Icon SVG File
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
/**
* Use em or rem font-size in Bootstrap 3
*/
@font-size-root: 14px;
@font-unit: 0rem; // Pick em or rem here
// Convert all variables to em
@remino
remino / favicon.sh
Last active August 29, 2015 14:06 — forked from lavoiesl/favicon.sh
#!/bin/bash
# Converts an image in a multi-resolution favicon
# Requires Imagemagick
if [[ "$#" != "2" ]]; then
echo "Usage: $0 input.png output.ico" >&2
exit 1
fi
input="$1"
Sass::Engine::DEFAULT_OPTIONS[:load_paths].tap do |load_paths|
load_paths << "#{Rails.root}/app/assets/stylesheets"
load_paths << "#{Gem.loaded_specs['compass'].full_gem_path}/frameworks/compass/stylesheets"
load_paths << "#{Gem.loaded_specs['html5-boilerplate'].full_gem_path}/stylesheets"
load_paths << "#{Gem.loaded_specs['fancy-buttons'].full_gem_path}/lib/stylesheets"
end
@remino
remino / Gemfile
Created May 22, 2015 02:43
Set up "exception_notification" for Rails 4 on staging at Heroku
group :staging do
gem 'exception_notification'
end
@remino
remino / dig.rb
Last active August 29, 2015 14:23 — forked from re5et/dig.rb
class Hash
def dig(*path)
path.inject(self) do |location, key|
location.is_a?(Hash) ? location[key] : nil
end
end
end
@remino
remino / getter_setter.js.coffee
Last active August 29, 2015 14:26
Helpers for JavaScript to easily define getters and setters in CoffeeScript
Function::getter = (prop, get) ->
Object.defineProperty @prototype, prop, {get, configurable: yes}
Function::setter = (prop, set) ->
Object.defineProperty @prototype, prop, {set, configurable: yes}
@remino
remino / sayit.sh
Created August 17, 2015 00:09
sayit: Read lines in a text file with the voice of your choice and output every line in its own .aiff file. (For OS X only.)
#!/bin/sh
sayit_main() {
[ $# -lt 3 ] && sayit_usage && return 1
script="$1"
voice="$2"
outdir="$3"
lineno=1
@remino
remino / jquery-objectified-plugin.js
Created January 5, 2012 05:46
Blank jQuery plugin with helper object
(function($) {
function FooBar($scope) {
this.$scope = $scope;
this.init();
};
FooBar.prototype.doNothing = function() { };
FooBar.prototype.init = function() {