Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does my MVC4 project not have debug and release folders under the bin folder?

When I build my app, I just get a single bin folder, with all files in it, versus the usual bin\debug and bin\release folders. Why is this?

like image 256
ProfK Avatar asked May 28 '13 04:05

ProfK


2 Answers

Because the website can be run by IIS ( and the various flavours of... ) in the location you built.

IIS expects the assemblies in the bin folder ( it's hard wired in the AppDomain setup ) so the web project type compile to this location.

like image 128
Robert Slaney Avatar answered Nov 16 '22 02:11

Robert Slaney


For an interview, i was put across with this question. One of the link could be this which answers in brief .

The above link will give you the statement as below:-

Release Mode

When an assembly is built in release mode, the compiler performs all available optimisations to ensure that the outputted executables and libraries execute as efficiently as possible. This mode should be used for completed and tested software that is to be released to end-users. The drawback of release mode is that whilst the generated code is usually faster and smaller, it is not accessible to debugging tools.

Debug Mode

Debug mode is used whilst developing software. When an assembly is compiled in debug mode, additional symbolic information is embedded and the code is not optimised. This means that the output of the compiler is generally larger, slower and less efficient. However, a debugger can be attached to the running program to allow the code to be stepped through whilst monitoring the values of internal variables.

[Update] After little google i came across similar question- "Confused about Release/Debug folders in Visual Studio 2010" with same answer which i have quoted above.

Also, please look into why-have-separate-debug-and-release-folders-in-visual-studio. @riko and other members of Stackoverflow have answered quiet well..

like image 40
Shubh Avatar answered Nov 16 '22 02:11

Shubh