Skip to content

Instantly share code, notes, and snippets.

David Acevedo rebelwarrior

Block or report user

Report or block rebelwarrior

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View SlightlyLessSimpleDropdown.elm
import Html exposing (..)
import Html.Attributes exposing (..)
import Html.Events exposing (on, targetValue)
import Json.Decode
main =
beginnerProgram { model = "", view = view, update = update }
View SimpleDropDown.elm
import Html exposing (..)
import Html.Attributes exposing (..)
import Html.Events exposing (on, targetValue)
main =
beginnerProgram { model = "", view = view, update = update }
view model =
rebelwarrior / supress_output.rb
Created Jan 24, 2018
Supresses Output to Terminal in Ruby
View supress_output.rb
# from
# on
def suppress_output
original_stdout, original_stderr = $stdout.clone, $stderr.clone
$stderr.reopen'/dev/null', 'w')
$stdout.reopen'/dev/null', 'w')
$stdout.reopen original_stdout
rebelwarrior /
Created Jan 11, 2018 — forked from nitinhayaran/
OSX configurations
echo "Expanding the save panel by default"
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true
echo "Why is this not default anymore?! Enabling full keyboard access for all controls (e.g. enable Tab in modal dialogs)"
defaults write NSGlobalDomain AppleKeyboardUIMode -int 3
echo "I'm in yer computer, hax0ring yr passwords!"
echo "Requiring password immediately after sleep or screen saver begins"
defaults write askForPassword -int 1
rebelwarrior / Poirot_SetUp.rake
Last active Nov 15, 2017
Rake Task to Add Poirot's pre commit git hooks
View Poirot_SetUp.rake
namespace :poirot do
desc "Sets up Poirot's Git hooks for the local .git repository."
task :install_githooks do
def poirot_bash_script
#!/usr/bin/env bash
function setup_poirot()
# Output to stderr
rebelwarrior / identify_os.rb
Last active Nov 20, 2017
Identify OS with Ruby
View identify_os.rb
def idenfity_os
require 'rbconfig'
host_os = RbConfig::CONFIG['host_os']
case host_os
when /darwin/, /Mac/
when /linux/
when /cygwin|mswin|mingw|bccwin|wince|emx/
rebelwarrior / exportJOSMPrefs.xml
Created Apr 23, 2016
JOSM preferences for Puerto Rico
View exportJOSMPrefs.xml
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<preferences operation="append">
<maps key="imagery.entries">
<tag key="name" value="2010 USACE"/>
<tag key="type" value="tms"/>
<tag key="url" value="{zoom}/{y}/{x}"/>
<tag key="max-zoom" value="19"/>
rebelwarrior / rspec_model_testing_template.rb
Created Nov 9, 2015 — forked from kyletcarlson/rspec_model_testing_template.rb
Rails Rspec model testing skeleton & cheat sheet using rspec-rails, shoulda-matchers, shoulda-callbacks, and factory_girl_rails. Pretty much a brain dump of examples of what you can (should?) test in a model. Pick & choose what you like, and please let me know if there are any errors or new/changed features out there. Reddit comment thread: http…
View rspec_model_testing_template.rb
# This is a skeleton for testing models including examples of validations, callbacks,
# scopes, instance & class methods, associations, and more.
# Pick and choose what you want, as all models don't NEED to be tested at this depth.
# I'm always eager to hear new tips & suggestions as I'm still new to testing,
# so if you have any, please share!
# @kyletcarlson
# This skeleton also assumes you're using the following gems:

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
# Traducciones adicionales en
confirmed: "Su cuenta ha sido confirmada."
confirmed_and_signed_in: "Su cuenta ha sido confirmada. Ha sido identificado correctamente."
send_instructions: "Recibira un correo electrónico en unos minutos con instrucciones sobre cómo restablecer su contraseña."
send_paranoid_instructions: "Si su correo electrónico existe en nuestra base de datos recibirás un correo electrónico en unos minutos con instrucciones sobre cómo reiniciar su contraseña."
You can’t perform that action at this time.