Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| body { | |
| width: 100%; | |
| height: 500px; | |
| margin: 0; | |
| padding: 0; | |
| text-align: center; | |
| } | |
| body:before { | |
| display: inline-block; | |
| content: ' '; |
| # Encapsulate the configuration DSL pattern. | |
| # | |
| # Any `X=(value)` setter method on the given +obj+ is translated into `X(value)` method | |
| # in the context of this object. | |
| class ConfigDSL < BasicObject | |
| def initialize(obj, &config) | |
| @self = obj | |
| call(&config) | |
| end |
| // Inspired by http://css-tricks.com/vertically-center-multi-lined-text/ | |
| @mixin vertical-center-children($height: auto, $children: ':first-child') { | |
| display: table; | |
| height: $height; | |
| #{$children} { | |
| display: table-cell; | |
| vertical-align: middle; | |
| } | |
| } |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| #!/usr/bin/env ruby | |
| require 'rubygems' | |
| require 'twitter' | |
| require 'json' | |
| require 'faraday' | |
| # things you must configure | |
| PATH_TO_DROPBOX = "/Users/your_name/Dropbox/backup/tweets/" # you need to create this folder | |
| TWITTER_USER = "your_twitter_username" |
##git mergetool
In the middle file (future merged file), you can navigate between conflicts with ]c and [c.
Choose which version you want to keep with :diffget //2 or :diffget //3 (the //2 and //3 are unique identifiers for the target/master copy and the merge/branch copy file names).
:diffupdate (to remove leftover spacing issues)
:only (once you’re done reviewing all conflicts, this shows only the middle/merged file)
| var age = function age() { | |
| var dob = new Date(this.dob); | |
| var today = new Date(); | |
| var thisYear = today.getFullYear(); | |
| if (dob.getMonth() > today.getMonth() || | |
| dob.getMonth() === today.getMonth() && | |
| dob.getDate() >= today.getDate()) { | |
| thisYear -= 1; | |
| } |
| //Verison 0 | |
| 'use strict'; | |
| var counterFactory = function counterFactory() { | |
| return function() {}; | |
| }; | |
| var firstCounter = counterFactory(); | |
| // firstCounter contains a reference to | |
| // a new instance of the minimal function |
I am trying to run this. I am able to post to the table through Rails C, so I have access from there.
curl --request POST --header "Authorization: Token token="d168c8333a2b72bf7ad7bfe4bb9c669d" --header "Content-Type: application/json" -d '{
"beer": {
"name":"UFO"
"brewery":"Harpoon"
"style":"Hefe"
"location_id":"11"
}