Skip to content

Instantly share code, notes, and snippets.

View Auraelius's full-sized avatar

Al Zimmerman Auraelius

  • Pragmatic Design Studio
  • Portland, OR
  • X @auraelius
View GitHub Profile
@Auraelius
Auraelius / sample_app.rb
Created October 23, 2013 21:15
A sample sinatra application for code challenge 3
# sample/sample_app.rb
require 'sinatra'
require 'pry'
# We us "classic" mode where you don't actually see the class
# inheriting from Sinatra::Base and you don't start the app with
# rackup. This makes the object structure less obvious but lets
# Sinatra do more of the behind-the-scenes
@Auraelius
Auraelius / app.rb
Created May 30, 2014 14:28
PCC Sinatra Demo
require 'sinatra' # simple web framework
require 'data_mapper' # metagem, requires common plugins too.
# need to install dm-sqlite-adapter
DataMapper.setup(:default, "sqlite3://#{settings.root}/dictionary.sqlite3")
set :port, 4000 # port and binding set for Nitrous.io debugging
set :bind, '0.0.0.0'
# You don't have to define the instance variables, DataMapper does that.
@Auraelius
Auraelius / app_no_comments.rb
Created May 30, 2014 14:33
PCC Sintra demo without comments
require 'sinatra'
require 'data_mapper'
DataMapper.setup(:default, "sqlite3://#{settings.root}/dictionary.sqlite3")
set :port, 4000
set :bind, '0.0.0.0'
class Entry
include DataMapper::Resource
property :id, Serial
property :word, String
@Auraelius
Auraelius / gist:e852192fb062c0d9218b
Created October 27, 2014 19:52
;fldksjf;sadlkfj;lksdajf
v/zxkcmv/zxclmv/.zxc,vm/xzc.,vm/xzcv,mxzc
@Auraelius
Auraelius / js-jq-assignment-1-template.html
Created February 16, 2015 21:11
JavaScript / jQuery assignment template file
<html>
<head>
<title>JavaScript &amp; jQuery Example</title>
<!--
We put the styles here just to keep the assignment all in one file.
Normally they go in separate files.
-->
<style type="text/css">
<html>
<head>
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<style>
body {
font-family: "Open Sans", sans-serif;
}
</style>
</head>
@Auraelius
Auraelius / gist:7eedd27d1c8c9b38bd3c
Created May 8, 2015 01:57
How to run Sublime Text from the command line on OSX
# this is a comment
#
# "mkdir ~/bin" makes a "bin" folder in your home folder. this is a good place to put your own programs
# "rm ~/bin/subl" removes any "subl" command that you might already have
# 'ln -s "/Appli...."' links "subl" to the app in your Applications folder
# cut and paste these commands into your terminal shell:
mkdir ~/bin
rm ~/bin/subl
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" ~/bin/subl
@Auraelius
Auraelius / glossary_localStorage.html
Created May 12, 2015 02:59
local storage glossary
<html>
<head>
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<style>
body {
font-family: "Open Sans", sans-serif;
}
textarea {
height: 5em;
width: 40em;
JavaScript Immersion Retrospective 20150902
* Please feel free to edit and add to this etherpad. You can remain anonymous if you wish.
* If you prefer, you can send us anonymous feedback at https://docs.google.com/forms/d/1Ix-5grMUdFm00ilb4_EqCLUd5jfJaOC900r-kfUHjqk/viewform
* And, please contact Kristina, Cris, or Collaine if you have concerns that you would prefer to discuss in person.
We will ask everybody to contribute something in both of the following areas. When it's your turn, if you agree with something that's already here, that's great. Please +1 the existing comment and then also tell us your perspective.
JavaScript Evening Retrospective 2015/09/02
* Please feel free to edit and add to this etherpad. You can remain anonymous if you wish.
* If you prefer, you can send us anonymous feedback at https://docs.google.com/forms/d/1Ix-5grMUdFm00ilb4_EqCLUd5jfJaOC900r-kfUHjqk/viewform
* And, please contact Kristina, Cris, or Collaine if you have concerns that you would prefer to discuss in person.
We will ask everybody to contribute something in both of the following areas. When it's your turn, if you agree with something that's already here, that's great. Please +1 the existing comment and then also tell us your perspective.
What is working well?