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/bash | |
directory="4chan header images" # the directory to download the images to | |
mkdir "$directory" | |
pushd "$directory" > /dev/null | |
curl -Of http://s.4cdn.org/image/title/[0-262].png | |
popd > /dev/null |
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'); | |
// Returns an Array of all directories in the current directory. | |
function getDirectories() { | |
return fs.readdirSync('.').filter(function (file) { | |
return fs.statSync(file).isDirectory(); | |
}); | |
} | |
// Returns a copy of the given Array with all elements of the blacklist Array |
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
# Deploy to Heroku in production | |
task deploy: ['deploy:push', 'deploy:migrate'] | |
namespace :deploy do | |
APP = 'openatrit' | |
task :push do | |
puts 'Deploying site to Heroku ...' | |
puts `git push -f [email protected]:#{APP}.git master` | |
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
print <STDIN>; |
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
require 'open-uri' | |
changelog = open 'https://raw.githubusercontent.com/angular/angular.js/master/CHANGELOG.md' | |
headlines = changelog.grep(/^# /) | |
headlines.each do |headline| | |
version, codename = headline.match(/(\S+) +(\S+) +\([\d-]+\)/).captures | |
puts "#{version}: #{codename}" | |
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
# See https://github.com/paircolumbus/Functional-101/blob/nicks-solution/ex4-remove-state.rb | |
# Constants | |
DEFAULT_ROUNDS = [Array.new(3, 1)] | |
DEFAULT_TIME = 4 | |
NEWLINE = "\n" | |
# Game functions | |
def should_move_position? |
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
:uri: http://example.com/?host=<%= hostname %> |
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
node_modules |
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
#!/usr/bin/env bash | |
for transform in node_modules/5to6-codemod/transforms/*.js; do | |
jscodeshift -t "$transform" $@ | |
done |
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
4:24 | |
1:58 | |
4:47 | |
3:44 | |
3:55 | |
1:53 | |
6:49 | |
4:04 | |
12:01 | |
3:24 |