Hi there!
The docker cheat sheet has moved to a Github project under https://github.com/wsargent/docker-cheat-sheet.
Please click on the link above to go to the cheat sheet.
# Compresses all .js and .css files under the assets path. | |
namespace :deploy do | |
# It is important that we execute this after :normalize_assets because | |
# ngx_http_gzip_static_module recommends that compressed and uncompressed | |
# variants have the same mtime. Note that gzip(1) sets the mtime of the | |
# compressed file after the original one automatically. | |
after :normalize_assets, :gzip_assets do | |
on release_roles(fetch(:assets_roles)) do | |
assets_path = release_path.join('public', fetch(:assets_prefix)) | |
within assets_path do |
export PROMPT_COMMAND='prompt_status=$?' | |
export PS1='$(if [[ $prompt_status == 0 ]]; then echo "ᕕ( ᐛ )ᕗ"; else echo "¯\_(ツ)_/¯"; fi)' |
# Usage: | |
# | |
# ruby irpf.rb tax_base | |
# | |
# Example: | |
# | |
# ruby irpf.rb 65300 | |
# 65300 €, 22722 €, 34.8% | |
# | |
# Where 22,722 € is the IRPF to pay, and 34.8% is the real rate, that is, |
RSpec.configure do |config| | |
config.before(:suite) do | |
DatabaseCleaner.clean_with(:truncation) | |
end | |
config.before(:each) do | |
DatabaseCleaner.strategy = :transaction | |
end | |
config.before(:each, js: true) do |
Hi there!
The docker cheat sheet has moved to a Github project under https://github.com/wsargent/docker-cheat-sheet.
Please click on the link above to go to the cheat sheet.
require 'rubygems' | |
require 'mechanize' | |
FIRST_NAME = 'FIRST_NAME' | |
LAST_NAME = 'LAST_NAME' | |
PHONE = 'PHONE' | |
EMAIL = '[email protected]' | |
PARTY_SIZE = 2 | |
SCHEDULE_RANGE = { :start_time => '19:00', :end_time => '20:30' } |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
Ideas are cheap. Make a prototype, sketch a CLI session, draw a wireframe. Discuss around concrete examples, not hand-waving abstractions. Don't say you did something, provide a URL that proves it.
Nothing is real until it's being used by a real user. This doesn't mean you make a prototype in the morning and blog about it in the evening. It means you find one person you believe your product will help and try to get them to use it.
# Change this to your blog URL... | |
export TUMBLR_URL="http://zeke.tumblr.com" | |
# As of this writing, jekyll and jekyll-import are busted. :( | |
gem uninstall jekyll -aIx | |
# Install an old version of jekyll that includes a migration script | |
gem install jekyll -v 0.11.2 | |
# Install a python package that converts HTML to Markdown |