ReSharper is a wonderful add-in tool for use with Microsoft's Visual Studio.
- General goal for programmers: Don't Use The Mouse
Use keyboard short cuts instead.
Remove the icons at the top of Visual Studio to force you to learn the shortcuts.
(Keyboard Jedi is a great tool for demos to show key combinations.)
- First Step: Set Two Defaults
- Set Keymapping Scheme
ReSharper/Options.../General/ Restore ReSharper keyboard shortcuts:/Resharper 2.x or IntelliJ IDEA
- Set Cache location
ReSharper/Options.../General/System/Store caches in / system TEMP folder
- Makes Larger IntelliSense Fonts
ReSharper/Options/IntelliSense/Completion Appearance/Display completion/Text Editor
- Highlight With Outline
ReSharper/Options/Environment/Editor/Braces and parentheses / Highlight with outline
ReSharper/Options..../Environment /Editor/Select "Use CamelHumps"
- Whole Project Analysis
ReSharper / Options / Code Inspection Settings / Analysis Errors in Whole Project
- Set Keymapping Scheme
- Set Code Inspection Severity
Open Survey.cs, look at sealed rule and change severity (ReSharper/Options.../Code Inspection/Inspection Severity)
- Naming rules (new 4.5 feature)
Open Survey.cs look at "const" (Options/Languages/Common/NamingStyle)
Key Chord Description Shift-Alt-l Locate current file in solution explorer shift-escape If focus is in solution explore, this hides it Esc Backout of current operation Alt-Enter Context-sensitive ReSharper hints Ctl-w Widen highlighted area Ctl-l Delete current line Ctl-d Duplicate current line F12 Go to next ReSharper issue Shift-F10 Shows context-menu, right mouse
Example: Undo the checkout of a file with only the keyboard.
Key Chord Description Ctl-n find type. CanUseCamelCase: GS Ctl-shift-n find file. Can use wild-cards: *.xslt Ctl-shift-Alt-n find symbol (a method/field... on any object) Ctl-F12 find member. CanUseCamelCase: GSKQ Ctl-b go to method under cursor. Even works in nant to go to target. Ctl-Alt-b go to implementation of interface method Ctl-f12 shows all methods in object Ctl-shift-backspace go to previous edit point Ctl-tab shows files, puts in previous file Ctl-e recently visited files Ctl-Alt-7 find all usages
- Live Template Lab: Person object.
- Alt-Insert to create a Person class.
- Usage: enter abbreviations followed by tab.
- Examples: psvm, out, outv, prop
- Create cir (ReSharper/Live Templates.../User Templates/C# right-click)
- Create post (public override string ToString()) with $END$
- "new Person()" Ctl-Alt-v abstract variable creates receiving variable
- Ctl-Alt-j for surround templates for exception handling
- Alt-Enter for split assignment / F12 / Alt-Enter for initialize variable
- Live Templates / XML built in t, tc, a / /
- Refactor Lab:
Key Chord Description F2 rename local variable Ctl-Alt-v introduce variable Ctl-Alt-m extract method Ctl-F6 change method signature Ctl-R inline method
- IntelliSense on steroids
Key Chord Description Ctl-Space Gets IntelliSense, Ctl-Alt-Space Gives ALL IntelliSense Ctl-shift-Space Gives only valid objects
- Miscellaneous Key Mappings
F6 moves class to new file Ctl-u find parent Ctl-shift-F7 color codes variable Alt-delete safe delete Alt-rnc creates new class Ctl-shift-b build Ctl-r Ctl-w show white space
- Native VS2008 Key Mappings
Key Chord Description Ctl-i for incremental search in vs2008 c-shift-v cycle paste buffers Alt-br to rebuild solution Ctl-shift-z : undo undos