6

In Habitat, we have gulp tasks for:

  • Publish All Projects
  • Publish-Foundation-Projects
  • Publish-Feature-Projects
  • Publish-Project-Projects

I want to publish a single Project. I can use msbuild, as described here: https://docs.microsoft.com/en-us/aspnet/web-forms/overview/deployment/visual-studio-web-deployment/command-line-deployment - but I'm not sure this will work, as the Gulpfile pulls in config from gulp-config.js, and performs tasks such as 'Apply XML transform' and 'Sync unicorn'.

What's the recommended way to publish a single Habitat project?

  • 2
    Does this need to be done via gulp, or have you tried just right clicking on the project and publishing the project directly? – Dylan Young Jun 16 '17 at 15:33
  • I can definitely publish from Visual Studio - there's no problem there. Would this miss out any crucial steps of the build pipeline? I see that Gulp does things like 'Apply XML Transform' and 'Sync Unicorn' – peaks Jun 16 '17 at 15:35
  • 1
    Nope - @DylanYoung is right - the publish tasks in gulp just do the same as right-click -> publish – Richard Seal Jun 16 '17 at 15:45
  • Thanks both. Happy to accept your answer, if you can make it answerable :) – peaks Jun 16 '17 at 15:47
  • Any reason why you don't want to write a gulp task to publish and then apply your transforms and/or sync? – Zachary Kniebel Jun 16 '17 at 15:51
6

You can publish a single project by right clicking on the project and selecting the Publish option in Visual Studio. Or if you have Click Once publishing toolbar open, you can select the project and publish by clicking the Publish Web button.

Typically I will use this process when I am working on a single project, vs waiting for all the projects to complete publishing.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.