Displays the different color categories available in (D3.js)[https://github.com/mbostock/d3/wiki/Ordinal-Scales#categorical-colors]
This file contains hidden or 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/bash | |
| iface=$1 | |
| echo "Restarting $iface" | |
| ifdown $iface | |
| sleep 5 | |
| ifup $iface |
This file contains hidden or 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
| POST /cdndata HTTP/1.1 | |
| Host: c.xkcd.com | |
| Connection: keep-alive | |
| Content-Length: 9265 | |
| Cache-Control: no-cache | |
| Pragma: no-cache | |
| Accept: */* | |
| Origin: http://xkcd.com | |
| User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.114 Safari/537.36 OPR/22.0.1471.50 | |
| Content-Type: application/x-www-form-urlencoded; charset=UTF-8 |
This file contains hidden or 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/bash | |
| # Lets us read from the keyboard | |
| exec < /dev/tty | |
| bundle exec rake develop | |
| passed=$? | |
| if [ $passed -ne 0 ] | |
| then |
This file contains hidden or 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
| `git branch -l` | |
| .split("\n").map { |branch| branch.strip } | |
| .select { |branch| branch[/(feature|hotfix)\//] } | |
| .each { |branch| `git branch -d #{branch}` } |
This file contains hidden or 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
| diff --git a/ext/readline/extconf.rb b/ext/readline/extconf.rb | |
| index 4920137..b351533 100644 | |
| --- ext/readline/extconf.rb | |
| +++ ext/readline/extconf.rb | |
| @@ -19,6 +19,10 @@ def readline.have_func(func) | |
| return super(func, headers) | |
| end | |
| +def readline.have_type(type) | |
| + return super(type, headers) |
This file contains hidden or 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
| # Code is way too verbose | |
| class HashStore | |
| attr_writer :store | |
| def store | |
| @store ||= Hash.new | |
| end | |
| def add_value(scope, value) | |
| it store.has_key?(scope) && store[scope].is_a?(Array) |
This file contains hidden or 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
| # auth.gemspec | |
| require 'auth/version' | |
| Gem::Specification.new do |s| | |
| ... | |
| s.add_dependency 'rails', '~> 4.0.4' | |
| s.add_dependency 'devise', '~> 3.2.4' | |
| s.add_development_dependency 'sqlite3' |
This file contains hidden or 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 d = new Date('2014-03-14'); |
This file contains hidden or 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
| Failure/Error: expect{ FileImporter.new }.not_to raise_error ArgumentError | |
| ArgumentError: | |
| `expect { }.not_to raise_error(SpecificErrorClass)` is not valid, use `expect { }.not_to raise_error` (with no args) instead |