Function | Shortcut |
---|---|
New Tab | ⌘ + T |
Close Tab or Window | ⌘ + W (same as many mac apps) |
Go to Tab | ⌘ + Number Key (ie: ⌘2 is 2nd tab) |
Go to Split Pane by Direction | ⌘ + Option + Arrow Key |
Cycle iTerm Windows | ⌘ + backtick (true of all mac apps and works with desktops/mission control) |
Changing to iso 1806 style dates cuz who needs anything else amiright?
DISTINCT ON
with ORDER BY
acts acts like window functions with ranking/row_number. https://www.youtube.com/watch?v=XuGxGP8quMQ
-- Set the variable "query" to the contents of the sql file
\set query `cat my_rad_query.sql`
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
# FOR BUSY JOBS | |
# take the process_id from the /busy page in sidekiq and kill the longest running one. | |
workers = Sidekiq::Workers.new | |
long_process_id = 'integration.3:4:71111aaa111' # Eg: 'integration.3:4:71d1d7f4ef5a' | |
workers.each do |process_id, thread_id, work| | |
process = Sidekiq::Process.new('identity' => process_id) | |
process.stop! if process_id == long_process_id | |
end | |
# FOR SCHEDULED JOBS |
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/sh | |
# ./.git/hooks/pre-commit | |
.git/hooks/pre-commit-format-javascript | |
.git/hooks/pre-commit-format-ruby |