Short (72 chars or less) summary
More detailed explanatory text. Wrap it to 72 characters. The blank
line separating the summary from the body is critical (unless you omit
the body entirely).
Write your commit message in the imperative: "Fix bug" and not "Fixed
bug" or "Fixes bug." This convention matches up with commit messages
Thanks for watching my talk, Domain-Driven Desire at Øredev 2016. Here's a list of resources that inspired me, and will hopefully inspire you:
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
1) install npm packages | |
2) update brunch-config.js | |
3) remove Bootstrap from web/static/css/app.css | |
4) rename web/static/css/app.css to web/static/css/app.scss | |
5) update web/static/css/app.scss |
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
defmodule EctoBatchStream do | |
import Ecto.Query, only: [from: 1, from: 2] | |
@batch_size 1000 | |
# Example: | |
# | |
# query = from u in MyApp.User, select: u.email | |
# stream = EctoBatchStream.stream(MyApp.Repo, query) | |
# stream |> Stream.take(3) |> Enum.to_list # => […] |
# env.rb or spec_helper.rb
Capybara.register_driver :poltergeist do |app|
opts = {
extensions: ["#{Rails.root}/features/support/phantomjs/disable_animations.js"] # or wherever
}
Capybara::Poltergeist::Driver.new(app, opts)
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
CREATE TEXT SEARCH CONFIGURATION fr ( COPY = french ); | |
ALTER TEXT SEARCH CONFIGURATION fr ALTER MAPPING | |
FOR hword, hword_part, word WITH unaccent, french_stem; | |
CREATE TEXT SEARCH CONFIGURATION en ( COPY = english ); | |
ALTER TEXT SEARCH CONFIGURATION en ALTER MAPPING | |
FOR hword, hword_part, word WITH unaccent, english_stem; | |
CREATE TEXT SEARCH CONFIGURATION de ( COPY = german ); | |
ALTER TEXT SEARCH CONFIGURATION de ALTER MAPPING |
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
gem 'kaminari' # Pagination |
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 | |
# Kill an Erlang process by node name | |
# | |
# e.g.: kill-erlang-node kred | |
# Check usage | |
if [ -z "$1" ]; then | |
echo "Usage: `basename $0` NODE_NAME" | |
exit 1 |
This script installs a patched version of ruby 1.9.3-p194 with patches for boot-time performance improvements (#66 and #68), and runtime performance improvements (#83 and #84). It also includes the new backported GC from ruby-trunk.
Huge thanks to funny-falcon for the performance patches.
NewerOlder