This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module('myApp', []) | |
.controller('AddController', | |
function($scope) { | |
$scope.cities = [{ | |
"name": "Carson City, Nevada", | |
"region": "Nevada", | |
"country_code": "US" | |
}, | |
{ | |
"name": "Castle Rock, Colorado", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Cleanup docker files: untagged containers and images. | |
# | |
# Use `docker-cleanup -n` for a dry run to see what would be deleted. | |
untagged_containers() { | |
# Print containers using untagged images: $1 is used with awk's print: 0=line, 1=column 1. | |
# NOTE: "[0-9a-f]{12}" does not work with GNU Awk 3.1.7 (RHEL6). | |
# Ref: https://github.com/blueyed/dotfiles/commit/a14f0b4b#commitcomment-6736470 | |
docker ps -a | tail -n +2 | awk '$2 ~ "^[0-9a-f]+$" {print $'$1'}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="menuExample"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(setq backup-directory-alist `(("." . ,(concat user-emacs-directory | |
"backups")))) | |
(setq auto-save-default nil) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react/addons'; | |
import {RouteHandler,Navigation,Link, State} from 'react-router'; | |
import {AuthenticationMixin} from '../mixins/authentication'; | |
import {IntlMixin} from 'react-intl'; | |
import SessionStore from '../stores/session_store'; | |
import NavBarHeader from '../components/Navbar'; | |
export default React.createClass({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var path = require('path'); | |
var webpack = require('webpack'); | |
var glob = require("glob"); | |
var _ = require('lodash'); | |
var cwd = process.cwd(); | |
var version = require(path.resolve(cwd,'package.json')).version; | |
var makeConfig = function(opts) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## That's one way... | |
# Think we can make this less ruby-specific? | |
solution :myapp do | |
cloud :db do | |
mysql :master => 1, :max_slaves => 4 | |
end | |
cloud :web do | |
rails ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
solution :myapp do | |
cloud :db do | |
mysql :master => 1, :max_slaves => 4 | |
end | |
cloud :web do | |
rails ... | |
nginx ... | |
end | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pool :poolpartyrb do | |
plugin_directory "plugins" | |
cloud :app do | |
# Configuration | |
configure { :maximum_instances => 1,:keypair => "name" } | |
minimum_instances 1 | |
apache do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TextInputField extends React.Component { | |
constructor(props, state) { | |
super(props, state); | |
} | |
blur() { | |
setTimeout(() => this.refs.input.blur(), 0); | |
} | |
focus() { |