sayedihashimi / package-web

Extensions for ASP.NET web projects package creation
32 stars 18 forks source link

Minor updates to deal with quotes and spaces #22

Open sayedihashimi opened 12 years ago

sayedihashimi commented 12 years ago

I received the comments below from someone using package-web we should updated it with his changes.

• In line 414 (in our version) (function PublishWithMSDeploy), we replaced Invoke-Expression $cmdFile with .$cmdFile because if the web app’s project name (=folder name) has a space in it, the script would fail (it works if we don’t use Invoke-Expression). • Around line 338 (function BuildMSDeployCommand) we had to add quotes around the site name for another space/escaping issue. • Around line 295 (function CreateSetParametersFile), we added another if statement to never include the “Add write permission to App_Data Folder”. We had to do this because for some reason the IIS web app name wouldn’t resolve properly (not sure if this is an issue in your script or VS but I suspect VS). It would still end up in the final version of SetParameters.xml as “{IIS Web Application Name}/App_Data”.