Avoid accidental rebuild of a project in Visual Studio
Asked Answered
T

3

10

I often click on "rebuild" by accident when I actually want to click "build". This rebuild process may take so long time if there are dependencies of this project...

Do you know any plug-in or a configuration that makes visual studio to ask me if I am sure to rebuild this project?

I hope there is a way to handle this situation.

Thalamencephalon answered 14/9, 2009 at 8:34 Comment(4)
Have a look at IncrediBuild by www.xoreax.com. While it doesn't prevent you from doing the wrong thing, it definitely helps makeing the outcome of doing so less painful.Talapoin
It certainly was a stupid design decision to place these two menu entries next to each other. Makes me ask whether the VS devs ever use their own product.Miocene
@karx11erx: it makes no sense to not put them next to eachother. Maybe the VS devs just have decent eye-hand coordination? :)Distinguish
@sbi: it is good that i use IncrediBuild for these large build precesses but anyway i loose time even with IncrediBuild but before IncrediBuild there were so many times that i wanted to kill the VS developers :pThalamencephalon
U
18

Go to Tools, Customize. Amend the menus and/or toolbars to suit you. For example you might prefer a custom toolbar that contains just the functionality you want without a Rebuild button on it.

Also try bypassing the mouse altogether with the keyboard shortcut for build: Ctrl+Shift+B. There is no default keyboard shortcut for rebuild so there's no chance of activating that accidentally. (Also, the keyboard shortcuts can also be changed by clicking Keyboard at the bottom of the Customize dialog.)

Uncircumcised answered 14/9, 2009 at 11:32 Comment(1)
+1: I just did this. I had to go to Tools->Customize->Commands, hit the Context Menus radio button, and then hit the combo box and select "Project and Solutions | Project". That brought up the project context menu, where Build and Rebuild were together. I moved down Rebuild, tres bien!Trivandrum
D
2

Press F6 to Build (or Shift+F6 to build just one project). There is no hotkey for rebuild in any of the default setups (I think), so you can't hit it by accident ;)

Distinguish answered 14/9, 2009 at 8:38 Comment(0)
E
-3

You can hit Ctrl + Break to cancel a build.

Entrechat answered 22/12, 2009 at 16:37 Comment(1)
after cleaning the whole solution, do you think it matters to stop build?Thalamencephalon

© 2022 - 2024 — McMap. All rights reserved.