Skip to content

Instantly share code, notes, and snippets.

View Druwerd's full-sized avatar

Dru Ibarra Druwerd

  • Los Angeles, CA
View GitHub Profile
@Druwerd
Druwerd / clone-heroku-app
Created February 5, 2024 16:36 — forked from brunocalmels/clone-heroku-app
Script to clone a heroku app (including buildpacks, users, add-ons, environment variables, lab features)
#!/usr/bin/env ruby
# Copy a heroku app (buildpacks, add-ons, labs, config, users).
# This script is idempotent so it can run against an existing app.
#
# Usage:
# $> clone-heroku-app source-app target-app
require "json"
@Druwerd
Druwerd / partner_decision_engine.rb
Last active June 20, 2020 00:40
outbound partner decision engine
require 'wongi-engine'
include Wongi::Engine::DSL
class LoanApplication
attr_accessor :id, :years_in_business, :bankruptcy, :industry, :fico, :decline, :outbound_partners
def initialize(id:, years_in_business:, bankruptcy:, industry:, fico:)
@id = id
@years_in_business = years_in_business
@bankruptcy = bankruptcy
@Druwerd
Druwerd / brew config
Last active November 8, 2016 13:45
rbevn install 2.2.2 failure
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 01716720daea301618e9793e722f18bb9436ff2a
Last commit: 70 minutes ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
HOMEBREW_BOTTLE_DOMAIN: https://homebrew.bintray.com
CPU: quad-core 64-bit haswell
OS X: 10.10.4-x86_64
Xcode: 6.4
{
// The plugin looks for a .jsbeautifyrc file in the same directory as the
// source file you're prettifying (or any directory above if it doesn't exist,
// or in your home folder if everything else fails) and uses those options
// along the default ones.
// Details: https://github.com/victorporof/Sublime-HTMLPrettify#using-your-own-jsbeautifyrc-options
// Documentation: https://github.com/einars/js-beautify/
"html": {
"allowed_file_extensions": ["htm", "html", "xhtml", "shtml", "xml", "svg"],
(function () {
var root = angular.element(document.getElementsByTagName('body'));
var watchers = [];
var f = function (element) {
angular.forEach(['$scope', '$isolateScope'], function (scopeProperty) {
if (element.data() && element.data().hasOwnProperty(scopeProperty)) {
angular.forEach(element.data()[scopeProperty].$$watchers, function (watcher) {
watchers.push(watcher);
@Druwerd
Druwerd / hello-color.rb
Created August 12, 2011 06:30
colorful terminal output
#!/usr/bin/ruby
require "rubygems"
require "term/ansicolor"
class String
include Term::ANSIColor
end
puts "Hello World".red
@Druwerd
Druwerd / gist:750641
Created December 21, 2010 21:25
hello world
puts "hello world!"