I hereby claim:
- I am carpeliam on github.
- I am carpeliam (https://keybase.io/carpeliam) on keybase.
- I have a public key ASCaBaC8yV-Z-VIp5vDtbnw64YJ6UYl83SVwk-1gnCaieAo
To claim this, I am signing this object:
| class Cell | |
| attr_accessor :is_mine, :num_adjacent_mines | |
| def initialize | |
| self.num_adjacent_mines = 0 | |
| end | |
| def to_s | |
| if is_mine | |
| '*' | |
| else |
| class Player | |
| def play_turn(warrior) | |
| @health ||= warrior.health | |
| taking_damage = warrior.health < @health | |
| objects = warrior.look | |
| closest_enemy = objects.detect { |s| s.enemy? } | |
| closest_captive = objects.detect { |s| s.captive? } | |
| enemy_is_closer = closest_captive && closest_enemy && objects.index(closest_enemy) < objects.index(closest_captive) |
| // after running `vagrant ssh` to log into VM: | |
| // sudo su - osehra | |
| // cd ewdjs | |
| var ewdGlobals = require('ewdjs/lib/ewdGlobals'); | |
| var interface = require('nodem/lib/mumps'); | |
| var db = new interface.Gtm(); | |
| var util = require('util'); | |
| var ok = db.open(); | |
| ewdGlobals.init(db); |
| #!/bin/sh | |
| # | |
| # To enable this hook, rename this file to "pre-commit". | |
| PRY_PATTERN="require.+[\'\"]pry[\'\"]|binding\.pry" | |
| # Redirect output to stderr. | |
| exec 1>&2 | |
| if git diff --cached | grep '^\+' | grep -q -E $PRY_PATTERN; then | |
| echo "ERROR: There is left over pry stuff in this commit" |
| <link href="//fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,400,300,600,700" media="all" rel="stylesheet"> | |
| <h1>This is H1 Text</h1> | |
| <h2>This is H2 Text</h2> | |
| <h3>This is H3 Text</h3> | |
| <h4>This is H4 Text</h4> | |
| <h5>This is H5 Text</h5> | |
| <h6>This is H6 Text</h6> | |
| <hr> |
| #!/usr/bin/env ruby | |
| require 'spreadsheet' | |
| require 'capybara' | |
| require 'csv' | |
| include Capybara::DSL | |
| COL_CDCR = 0 |
I hereby claim:
To claim this, I am signing this object:
| def progress_bar(current, total, width=80) | |
| pos = (current.to_f / total * width).round | |
| print "\r|#{'=' * pos}#{'-' * (width - pos)}|" | |
| puts if current == total | |
| end |
| (function() { | |
| $.browser = {mozilla: false, webkit: false}; | |
| $('<script>').attr('src', 'https://cdn.jsdelivr.net/gh/davesierra/raptorize@master/jquery.raptorize.1.0.js').appendTo('body'); | |
| setInterval(function() { | |
| if ($('.pipeline-graph .started').length) { | |
| $(window).raptorize({enterOn: 'timer', delayTime: 0}); | |
| } | |
| }, 15000); | |
| }()); |
| import React from 'react'; | |
| import { connect } from 'react-redux'; | |
| function fetchIfNecessary(fetchWithProps, hasRequiredProp) { | |
| function mapDispatchToProps(dispatch, props) { | |
| return { fetch: () => dispatch(fetchWithProps(props)) }; | |
| } | |
| return (Component) => { | |
| class Fetcher extends React.Component { | |
| componentDidMount() { |