Date: October 11, 2017
People: Christine Chapman, Shayna Cummings, Stephanie Viccari
Link to Slides: https://christinezchapman.com/brookview
Questions
- Should we do two big projects that use Neocities and WordPress?
#!/usr/bin/env ruby | |
# encoding: UTF-8 | |
SUITS = ['♠', '♣', '♥', '♦'] | |
VALUES = ['2', '3', '4', '5', '6', '7', '8', '9', '10', 'J', 'Q', 'K', 'A'] | |
def build_deck | |
deck = [] | |
SUITS.each do |suit| |
#!/usr/bin/env ruby | |
#Purpose of Program | |
def set_up_game | |
word_bank = ["maverick", "boston", "apollo", "hangman", "developer"] | |
@word = word_bank.shuffle.first | |
@word_count = @word.length | |
puts "This word has #{@word_count} letters." | |
@guess_count = 10 | |
@count = 0 |
document.querySelectorAll(".show-outdated-button").forEach(function(i){i.click()}); |
Date: October 11, 2017
People: Christine Chapman, Shayna Cummings, Stephanie Viccari
Link to Slides: https://christinezchapman.com/brookview
Questions
#!/bin/sh | |
# | |
# Check for ruby style errors | |
red='\033[0;31m' | |
green='\033[0;32m' | |
yellow='\033[0;33m' | |
NC='\033[0m' | |
if git rev-parse --verify HEAD >/dev/null 2>&1 |
class AccountRegistration | |
include ActiveModel::Model | |
attr_accessor :email | |
validates :email, presence: true, format: { with: /.+@.+\..+/i } | |
end |
class Piranha::CampaignPerformance | |
def initialize(profile_amazon_id:, campaign_amazon_id:, date_range:) | |
@profile_amazon_id = profile_amazon_id | |
@campaign_amazon_id = campaign_amazon_id | |
@date_range = date_range | |
end | |
def all | |
response = piranha_client.get(daily_campaign_performance_uri) | |
handle_response(response) |
# config/initializers/rack_rewrite.rb | |
require "rack/rewrite" | |
Rails.configuration.middleware.insert_before(Rack::Runtime, Rack::Rewrite) do | |
# Content | |
r301 "/upcase/ruby", "/upcase/rails" | |
r301 "/upcase/sass", "/upcase/design" | |
r301 "/upcase/products", "/upcase/practice" | |
r301 "/upcase/users/new", "/upcase/join" | |
r301 "/upcase/sign_up", "/upcase/join" |
# example of working with a gem that always returns a response object | |
class Account | |
def find(account_id) | |
response = Hubspot::Account.find(account_id) | |
handle_response(response) | |
end | |
private | |
def handle_response(response) | |
if response.success? |