Skip to content

Instantly share code, notes, and snippets.

country = 'nl'
wdays = [3,5,6]
nl_zipcodes = CSV.read('zipcodes_nl.csv').map(&:first)
existing_zipcodes = DeliveryZip.for_country(country).pluck(:zip)
added_zips = nl_zipcodes - existing_zipcodes
existing_zips_not_in_file = existing_zipcodes - nl_zipcodes
ActiveRecord::Base.transaction do

Jumping, Finding, ...

Keybinding - Description
Ctrl-1 - Move to 1st tab (work every number)
Ctrl-p - Go to anything
Ctrl-g - Go to line
Ctrl-r - Go to symbol (e.g. section and labels)
Ctrl-m - Move to bracket