部署预编译的网站项目
所以我有一个网站项目,我在发布时预编译该项目。
我有一个问题,当我需要对已部署的网站进行小的更改时,我是否必须重新构建、重新发布和部署整个网站结构,或者我可以只复制修改后的aspx页面和bin目录吗?
请告诉我!
多谢你们!
So I have a website project, which I precompile when I publish.
I have a question, when I need to make a small change to the deployed site, do I have to rebuild, re-publish and deploy the entire website structure again, or can I just copy the modified aspx page and the bin directory?
Please let me know!
Thanks guys!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
这将取决于您如何进行网站的预编译。
根据MSDN,如果您为部署进行了预编译,则该过程接受 aspx 文件并处理其中的任何内部代码,因此您需要重新编译所有内容。
如果您为部署和更新进行了预编译,则不会考虑 aspx 文件,因此只要您所做的只是一些 UI 更改,您就可以毫无问题地推送更新的 aspx 文件。
It is going to depend on how you did the precompiling of the site.
According to MSDN, if you did a precompile for deployment, the process takes aspx files and processes any internal code in them, so you will need to recompile everything.
If you did a precompile for deployment and update, the aspx files are not taken into consideration, so provided all you did was some UI changes, you can push the updated aspx file up without issue.
您应该能够在本地重新发布,然后复制修改后的发布页面和 bin 文件夹。
您不需要上传所有内容。
You should be able to republish locally and then copy up the modified published pages and the bin folder.
You shouldn't need to upload everything.
如果您根据您选择的选项进行预编译,您可能可以编辑 .aspx 页面,即 HTML 代码,但不能编辑隐藏代码。
如果 .aspx 页面只是占位符,即它们内部是空的,除了单一评论,你不能。
If you pre-compile epending on the options you have chosen you may be able to edit the .aspx page i.e. HTML code, but not the code-behind..
If the .aspx pages become just placeholders i.e. they are empty inside except for a single comment, you cant.