Publish web site overwriting all files all the time

P

PokerMan

HI

When i publish my site, it overwrites all files. but when i have some large
files included such as mp3s. It overwrites these and even tho i havent
touched them it reuploads all of them. Anyway i can set it to not do this
for specific files?

Thanks
 
R

Rick Strahl [MVP]

Anyway i can set it to not do this
for specific files?'

No unfortunately not. The publish feature basically writes out a new copy of
the entire Web site and then pushes the whole thing up to the server. It's
ugly to say the least especially with stock projects. There's really no good
workaround for this because the ASP.NET compiler wipes the timestamps from
the files so there's no way to even manually diff the files based on dates.
You can manually do it via FTP off the output files.

There are some ways that can make this easier. One is Web Deployment
projects which can basically compile your entire code of the site into a
single assembly making update deployment a bit easier. Or you can use Web
Application Projects (part of SP1 of Visual Studio) which does codebehind
compilation. But neither of these solutions really offer you a dynamic
publish feature - you still have to manually manage updates or suffer
through uploading the same files even if they haven't changed.

I wrote an article on this topic some time ago that explains how all this
works and shows a few of the differences, but be forewarned it's not a quick
read <s>...

http://www.west-wind.com/presentations/AspNetCompilation/AspNetCompilation.asp


Hope this helps,

+++ Rick ---
 
P

PokerMan

Thanks Rick.



Rick Strahl said:
No unfortunately not. The publish feature basically writes out a new copy
of the entire Web site and then pushes the whole thing up to the server.
It's ugly to say the least especially with stock projects. There's really
no good workaround for this because the ASP.NET compiler wipes the
timestamps from the files so there's no way to even manually diff the
files based on dates. You can manually do it via FTP off the output files.

There are some ways that can make this easier. One is Web Deployment
projects which can basically compile your entire code of the site into a
single assembly making update deployment a bit easier. Or you can use Web
Application Projects (part of SP1 of Visual Studio) which does codebehind
compilation. But neither of these solutions really offer you a dynamic
publish feature - you still have to manually manage updates or suffer
through uploading the same files even if they haven't changed.

I wrote an article on this topic some time ago that explains how all this
works and shows a few of the differences, but be forewarned it's not a
quick read <s>...

http://www.west-wind.com/presentations/AspNetCompilation/AspNetCompilation.asp


Hope this helps,

+++ Rick ---


--

Rick Strahl
West Wind Technologies
www.west-wind.com/weblog
 
M

Mark Rae

One is Web Deployment projects But neither of these solutions really offer
you a dynamic publish feature

WDP allows you to exclude files and/or folders by using the ExcludeFromBuild
tag - I do this all the time...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top