I hereby claim:
- I am benoittgt on github.
- I am benoittgt (https://keybase.io/benoittgt) on keybase.
- I have a public key whose fingerprint is A53D 31EF 53DE DCF9 19B7 062B 3D72 1D83 9FFF 5B74
To claim this, I am signing this object:
| ==> Downloading http://ftp.postgresql.org/pub/source/v9.4.1/postgresql-9.4.1.tar.bz2 | |
| Already downloaded: /Users/benoitpro/Library/Caches/Homebrew/postgresql-9.4.1.tar.bz2 | |
| ==> Verifying postgresql-9.4.1.tar.bz2 checksum | |
| tar xf /Users/benoitpro/Library/Caches/Homebrew/postgresql-9.4.1.tar.bz2 | |
| ==> ./configure --disable-debug --prefix=/usr/local/Cellar/postgresql/9.4.1 --datadir=/usr/local/Cellar/postgresql/9.4.1/share/postgresql --docdir=/usr/local/Cellar/postgresql/9.4.1/share/doc/postgresql --enable-thread-safety --with-bonjour --with-gssapi --with-ldap --with-openssl --with-pam --with-libxml --with-libxslt --with-perl --with-tcl --with-uuid=e2fs | |
| checking build system type... x86_64-apple-darwin10.8.0 | |
| checking host system type... x86_64-apple-darwin10.8.0 | |
| checking which template to use... darwin | |
| checking whether to build with 64-bit integer date/time support... yes | |
| checking whether NLS is wanted... no |
| Running `rails console` attached to terminal... up, run.8280 | |
| Loading production environment (Rails 4.2.0) | |
| irb(main):001:0> Geocoder.search("12 rue de Rivoli Paris") | |
| Geocoder::ResponseParseError: Geocoder::ResponseParseError | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/base.rb:159:in `raise_error' | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/base.rb:186:in `rescue in parse_json' | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/base.rb:180:in `parse_json' | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/base.rb:193:in `parse_raw_data' | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/base.rb:169:in `fetch_data' | |
| from /app/vendor/bundle/ruby/2.0.0/gems/geocoder-1.2.7/lib/geocoder/lookups/google.rb:28:in `results' |
| #In pry-rails on my rails project | |
| require 'benchmark/ips' | |
| Benchmark.ips do |x| | |
| x.report("sql request") { User.where("EXISTS (SELECT 1 FROM groups_users WHERE groups_users.user_id = users.id AND groups_users.group_id IN (?))", [8939, 8950]).where("NOT EXISTS (SELECT 1 FROM groups_users WHERE groups_users.user_id = users.id AND groups_users.group_id IN (?))", [8942]).count | |
| x.report("active record") { (User.joins(:groups).where(groups: {id: ["8939","8950"]}) - User.joins(:groups).where(groups: {id: 8942})).count } | |
| x.compare! | |
| end |
| # I have this code: | |
| def destroy | |
| old_store = mobile_application.store | |
| users_ids = [1,2] | |
| super | |
| UpdateLastUpdatesWorker.perform_async old_store.id, users_ids | |
| mobile_application.last_update = mobile_application.old_last_update | |
| mobile_application.save! |
| require 'benchmark/ips' | |
| require 'mail' | |
| Benchmark.ips do |x| | |
| x.report("'[email protected]'.split('@')[1]") { '[email protected]'.split('@')[1] } | |
| x.report("Mail::Address.new('[email protected]').domain") { Mail::Address.new('[email protected]').domain } | |
| x.compare! | |
| end |
| "status Vundle | |
| set nocompatible " be iMproved, required | |
| filetype off " required | |
| " set the runtime path to include Vundle and initialize | |
| call plug#begin('~/.vim/plugged') | |
| " let Vundle manage Vundle, required | |
| Plug 'gmarik/Vundle.vim' | |
| Plug 'albfan/ag.vim' |
| Demo |
| git diff --name-only --diff-filter=AMR origin/develop | grep _spec.rb | xargs bin/rspec |
I hereby claim:
To claim this, I am signing this object:
| #!/bin/bash | |
| set -e | |
| version=`cat package.json | grep version | cut -d: -f2 | sed -e "s/\"//g" | sed -e "s/ //g" | sed -e "s/\,//g"` | |
| function_name=stats_refresher | |
| filename=$function_name-$version.zip | |
| region=eu-west-1 | |
| envs=(int demo prod) | |
| files_to_copy=( index.js package.json node_modules dist rds_config_from_env.js ) |