Raymond Lewallen

Sponsors

The Lounge

Advertisement

Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at imagehelp@codebetter.com
How do you clean up the files in a project quickly?

Put your hands on your keyboard, don’t touch the mouse.

CTRL-ALT-L; Down Arrow (to a file), Enter, CTRL-ALT-F, Enter, (F12, Alt-Enter, Enter (repeat all necessary loops)), CTRL-ALT-F, Enter, CTRL-S, CTRL-F4

Repeat until you reach the end of the file list.  *note* you have to have Resharper.  If you don’t, shame on you.  Your job is harder than mine.

Update:  This is using IntelliJ mappings.  The key sequences are as follows:

CTLR-ALT-L – move from editor window to solution explorer.

CTRL-ALT-F – reformat code

F12 – move to next error/problem/issue

ALT-ENTER – suggestions for fixing issue

CTRL-S – save the file

CTRL-F4 – close the fil


Posted 10-04-2007 1:04 PM by Raymond Lewallen
Filed under: ,

[Advertisement]

Comments

Joe Ocampo wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 2:57 PM

LOL...Thanks I didn't know you could do that at the solution level.  But theoretically you should only have to do this once and then work per file!

Raymond Lewallen wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 3:04 PM

Joe, yeah you can do the reformatting at the solution level.  That is very helpful.  As far as clearing the problems, that still has to be done file by file, but it doesn't get any easier than using Resharper and not touching your mouse.  That F12, Alt-Enter, Enter combo wipes out issues very quickly.

Developer wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 4:50 PM

CTRL-ALT-L; Down Arrow (to a file), Enter, CTRL-ALT-F, Enter, (F12, Alt-Enter, Enter (repeat all necessary loops)), CTRL-ALT-F, Enter, CTRL-S, CTRL-F4

...Yeah, your job looks really easy compared to mine.

Raymond Lewallen wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 4:56 PM

Developer,

What does that key combination do, since your sarcasm suggests that it is difficult compared to the solution it provides?

Let me guess, you don't have a clue.

Joe wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 6:05 PM

up down up down a b a b circle triangle LT RT down down start

inifinite lives 0wns j00

GadgetGadget.info - Gadgets on the web » How do you clean up the files in a project quickly? wrote GadgetGadget.info - Gadgets on the web » How do you clean up the files in a project quickly?
on 10-04-2007 8:52 PM

Pingback from  GadgetGadget.info - Gadgets on the web » How do you clean up the files in a project quickly?

cmyers wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 10:19 PM

That key combination is pretty ridiculous, even by the anti-Mouse crowd standards. That screams 'macro' or something.

Kinda reminds me of the old KonamiCode:  UUDDLRLRBASelectStart

Raymond Lewallen wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 10:33 PM

cmyers,

If you understand what you are getting out of that key combination, and how fast you can actually work when using it, I think you'd have a different point of view.

And you wouldn't want to macro that.  The F12, Alt-Enter, Enter combination you never know how many times you will loop, and you want to examine what the GCA is telling you about the problem to see if you want to address it with default suggestive solutions.

Dave Laribee wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 10:58 PM

i had to boot my windows vm just to try this...

Joe wrote re: How do you clean up the files in a project quickly?
on 10-04-2007 11:33 PM

Doesnt the latest (daily build/beta/whatever) r# do this at the solution level?  I mean, I'm happy for your bionic hands and will gladly chip in when it comes time to fit you for wrist braces, and I know you're a proud man with nice sunglasses, but come on, lets just drop 100mg of Zoloft to kill the OCD for the afternoon and clean the files up as we get to them.

Jeremy wrote re: How do you clean up the files in a project quickly?
on 10-05-2007 9:50 AM

You can also just select the solution in Solution Explorer and say "CTRL+ALT+F".  R# (at least 3.0.2, anyway) will automatically reformat every file it finds under the solution.

Same thing applies if select a project.

Hope this helps,

Jeremy

Jason Haley wrote Interesting Finds: October 5, 2007
on 10-05-2007 10:14 AM
Connor Peterson wrote re: How do you clean up the files in a project quickly?
on 10-05-2007 10:40 AM

Can you write out what these steps to?  My keyboard mappings must be set up different than yours because I just end up in the File Structure window.

Sergio wrote re: How do you clean up the files in a project quickly?
on 10-05-2007 12:49 PM
HI, I have resharper but my keybindings are different. What does this shortcuts do ?
Chris M wrote re: How do you clean up the files in a project quickly?
on 10-08-2007 5:26 AM

Or for the anti-alt.net guys, you can just right click on the solution and select "reformat code". ;)

unique corporate gifts wrote re: How do you clean up the files in a project quickly?
on 11-08-2007 10:28 PM

Thanks for sharing these shortcuts.  I can still remember way back in my younger days at school when the mouse wasn’t invented yet.  We were forced to memorize all shortcuts using the computer keyboard in order to deal head on with any error or issues every time we use the monster computer.

http://loopback.codebetter.com/blogs/raymond.lewallen/archive/2007/10/04/how-do-you-clean-up-the-files-in-a-project-quickly.aspx wrote http://loopback.codebetter.com/blogs/raymond.lewallen/archive/2007/10/04/how-do-you-clean-up-the-files-in-a-project-quickly.aspx
on 04-05-2008 9:52 AM

Add a Comment

(required)  
(optional)
(required)  
Remember Me?