Skip to content

Instantly share code, notes, and snippets.

View dimanyc's full-sized avatar

Dimitry Nazarov dimanyc

View GitHub Profile
@dimanyc
dimanyc / doskey.bat
Last active November 21, 2021 18:28 — forked from PierreMage/PowerShell-profile.ps1
Make your Windows command line better with doskey
:: http://technet.microsoft.com/en-us/library/bb490894.aspx
:: F7 = history
:: Alt+F7 = history -c
:: F8 = Ctrl+R
:: Use & to run multiple commands e.g.: command1 & command2
::
:: 1. Go to your Windows folder and find regedit.exe
:: 2. Head over to:
:: HKEY_LOCAL_MACHINE\Software\Microsoft\Command
:: or
@dimanyc
dimanyc / capybara cheat sheet
Last active March 2, 2016 00:02 — forked from zhengjia/capybara cheat sheet
capybara cheat sheet
=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
@dimanyc
dimanyc / gist:fd9568f4b58991c5b255a0d18adfd3d8
Created September 2, 2016 22:17 — forked from metaskills/gist:4065702
Example Of Other/Legacy DB Connection Management & Query Cache
# Assuming you champioin your other DB connection with a class.
module OtherDb
class Connection < ActiveRecord::Base
establish_connection :other_db
self.abstract_class = true
end
end
# Alway use the connection for other/legacy connections.