asp.net中bin目录下的 dll.refresh文件

首先找到了这篇文章http://www.cnblogs.com/haokaibo/archive/2010/07/31/1789342.html

然后找到一篇英文的文章http://monsur.xanga.com/2006/02/03/dll-refresh-and-asp-net/

The question is so simple I wonder why I haven’t encountered it before:  If web projects in Visual Studio 2005 don’t have project files, how do they know where to get external references?  (Ok, well I guess the question isn’t that simple).

For example, suppose I have three dlls on a network share that I want to include in my web project.  I can do this using “add reference”.  But without a unifying project file, how does the next person know to load those same three references?

The usual suspects include the solution file and the web.config.  But the solution file contains only solution level information.  And while the web.config file has an “assemblies” section, it has nothing to do with external references.

It turns out, the answer lies in these simple but scary *.dll.refresh files that litter the bin directory.  Every time you add an external reference, you’ll find a dll.refresh file right next to it.

They are simple because if you view them in a text editor, you’ll see they contain nothing more than the full path to the dll.

They are scary because I’ve never seen them before, and we are conditioned to never, ever check your bin directory into source control.  In fact, I’ve been saying “WTF are these stupid refresh files!?” and then promptly deleting them.

Turns out, these dll.refresh files are an exception to the rule, and they should go into source control.  Its the only way your web project will know where its references live.

I can’t really find much information about these little files, just this bug report:

 

Thank you for your feedback. This is actually by design. If you are using source control, you do not want to store dynamically changing files such as a dll or pdb file. However, the refresh file contains information on where to get the dll and pdb, and should be saved. BTW, the presence of a refresh file indicates that the dll and pdb is dynamic and can change. If you do not have a refresh file, this indicates the dll and pdb are not dynamic. In this case, the dll and pdb *will* be checked into source control.

In the meantime, the ASP.NET team is working on a Web Application project for Visual Studio 2005.  This takes the best parts of VS2003 and fuses it with the best of VS2005 and ASP.NET 2.0.  This includes a single project file for the web project, which gets around the dll.refresh file issue.

中文的文章提出的解决方法是,另外建立一个文件夹,单独来存放第三方的dll

时间: 2024-10-10 03:02:31

asp.net中bin目录下的 dll.refresh文件的相关文章

Android项目在eclipse中无法打包apk文件[bin目录下没生成apk文件]问题解决

后来我发现在eclipse的Preferences -> Android -> Build中有一项“Skip packaging and dexing until export or launch....”,原来这个选项默认是被勾选的,这个选项的意思是“跳过packing和dexing,直到export或者 launch...”,去掉这个选项即可解决问题. Android项目在eclipse中无法打包apk文件[bin目录下没生成apk文件]问题解决

JDK/bin目录下的不同exe文件的用途(转)

新安装完JDk 大家是否发现安装目录的bin文件夹有很多exe文件 下面就为大家讲解不同exe文件的用途 javac:Java编译器,将Java源代码换成字节代 java:Java解释器,直接从类文件执行Java应用程序代码 appletviewer(小程序浏览器):一种执行HTML文件上的Java小程序类的Java浏览器 javadoc:根据Java源代码及其说明语句生成的HTML文档 jdb:Java调试器,可以逐行地执行程序.设置断点和检查变量 javah:产生可以调用Java过程的C过程

JDK/bin目录下的不同exe文件的用途

安装完JDK,大家是否发现安装目录的bin文件夹有很多exe文件.下面就为大家介绍一下不同exe文件的用途. javac:Java编译器,将Java源代码换成字节代. java:Java解释器,直接从类文件执行Java应用程序代码. appletviewer:小程序浏览器,一种执行HTML文件上的Java小程序类的Java浏览器 javadoc:根据Java源代码及其说明语句生成的HTML文档. jdb:Java调试器,可以逐行地执行程序.设置断点和检查变量. javah:产生可以调用Java过

2个问题,解决tomcat启动一闪而过和运行tomcat/bin目录下的startup.bat时报错(the CATALINA_HOME environment variable is not defined correctly)

1.除手动使用开始菜单自启动或者程序启动TOMCAT时TOMCAT一闪而过,这时候是发生了错误,这时候我们打开BIN目录下的“startup.bat”文件,编辑,在结尾添加pause命名,这样在CMD下执行startup.bat时就会出错停止,这时候我们就知道是什么错误了. 2.运行tomcat/bin目录下的startup.bat时报错:the CATALINA_HOME environment variable is not defined correctly 碰到这个问题时的第一反应是添加

转载 .net中的dll.refresh文件和pdb文件

转载原地址: http://blog.csdn.net/lihuang319/article/details/6433727 dll.refresh文件 打开refresh文件,可以看到里面仅仅是个路径. 众所周知,.net的程序生成后会在bin目录下生成.dll文件,而.dll.refresh这个文件从何而来呢?那天无聊地google了下才知,这个东东是在你的项目中引用第三方程序集(是直接的)时自动生成的,这个.refresh文件存储了那个第三方文件的原始文件路径,如果该路径下的这个dll更新

生成解决方案,主项目的bin目录下没有其他项目生成的dll

问题说明: 我的项目组成: 主项目为:TaskUtlity 在生成解决方案的时候在TaskUtlity的bin目录下老是找不到ProBonus项目生成的dll. 解决方案: 1.打开sln文件,找到ProBonus项目的GUID. Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TaskUtility.ProBonus", "TaskUtility.ProBonus\TaskUtility.ProB

net开发过程中Bin目录net开发过程中Bin目录下面几种文件

.net开发过程中Bin目录下面几种文件格式的解释 在.NET开发中,我们经常会在bin目录下面看到这些类型的文件: .pdb..xsd..vshost.exe..exe..exe.config..vshost.exe.config 项目发布的时候,往往搞不清楚哪些是需要的,那些是不需要的.那么这些格式的文件到底是干什么用的呢? pdb .pdb文件,是VS生成的用于调试的符号文件(program database),保存着调试的信息.在VS的工程属性,C/C++,调试信息格式,设置/Zi,那么

基础才是重中之重~网站bin目录下的程序集自动加载

回到目录 网站bin目录下的程序集一般由系统项目,项目引用的外部DLL及外挂DLL组成,它们在网站运行时会自动加载,这一点很重要,项目本身DLL及项目引入的DLL会自动加载,这没有问题,而外挂在bin目录的DLL也会自动加载,这很重要,因为,它可以使我们的应用程序更加灵活,在开发通用功能上,也显得扩展性更强! 一个例子,比如一个HttpModule,它是一个通用的功能,向页面添加一些缓存过期的共用信息,这对于你所有网站都是共用的,这时,可以建立一个HttpModule项目,它代码可能是这样 na

JavaWeb项目中WEB-INF目录下class文件自动生成以及显示

问题一:WEB-INF目录下的class字节文件是自动生成的,还是需要手动创建相关目录,然后再将字节件复制进去? 可以让eclipse自动生成 source folder:存放.java源文件的根目录 output folder:.class编译输出的根目录纯"java project"中,一般把"src"设置为source folder,把bin设置为output folder "web project"中,一般把"src"