Skip to content

Instantly share code, notes, and snippets.

🚀
Building Quality Software and Teams

Justin Herrick jah2488

🚀
Building Quality Software and Teams
Block or report user

Report or block jah2488

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
@jah2488
jah2488 / 1-solution.rb
Created May 17, 2019
The many phases of Raindrops from Exercism.
View 1-solution.rb
require 'prime'
module Raindrops
extend self
def convert(n)
primes = n.prime_division.flatten
if primes.any? { |x| [3,5,7].include?(x) }
primes.map do |x|
case x
when 3 then 'Pling'
View feed_seeder.rb
# Sample usage
# cd to book folder
# ruby feed_seeder.rb && dropcaster > index.rss && aws s3 sync . "s3://audiobooks-rss/My Book Name" --acl public-read
require 'colorize'
require 'optparse'
DEFAULT_DESCRIPTION = "Books are cool"
DEFAULT_IMAGE = "https://pbs.twimg.com/profile_images/378800000448533787/c32fb13e160ee7cd17848e8cacbbcfc5_400x400.jpeg"
DEFAULT_PATH = "."
View foo.json
{
"questions": [
{
"id": 1,
"displayName": "Favorite Food?",
"type": "text"
},
{
"id": 2,
"displayName": "Favorite Character Build",
View elm.md

Elm Resources

So you want to learn Elm? Excited to hear it. To get started, its going to help to have some guidance along the way. Below I've collected various helpful resources and tips to get you started.

Starting Out

Things To Do

View elm.md

Elm Resources

So you want to learn Elm? Excited to hear it. To get started, its going to help to have some guidance along the way. Below I've collected various helpful resources and tips to get you started.

Starting Out

Things To Do

@jah2488
jah2488 / setup.rb
Last active May 3, 2017
A setup script for a new laptop. (Assumes you have homebrew and homebrew cask installed)
View setup.rb
class Package < Struct.new(:command, :name, :opts)
def install!
if not_installed?
system("#{command} install #{name} #{opts.join(" ")}")
end
end
def not_installed?
!exists?
end
View example.css
html {
background: #F7F7F7;
color: red;
height: 100%;
}
body {
min-height: 100%;
}
.wrapper {
@jah2488
jah2488 / Main.elm
Last active Mar 21, 2017
Do now for Tuesday the 21st of March. Converting a string into a dictionary by last names.
View Main.elm
module Main exposing (..)
import Html exposing (Html, div, text)
import Dict exposing (Dict)
names : String -> Dict String (List String)
names str =
str
|> String.split ", "
|> List.map (\name -> String.split " " name)
View either_or.rb
# Structured and Nested
obj = {
container_a = {
name: "Foo",
contents: [item_a, item_b, item_e]
}
container_b = {
name: "Bar",
contents: [item_c, item_d, item_z]
}
You can’t perform that action at this time.