Comments (11)
Found a work-around for situations where VS2017 is also installed, which is to force gulp to use 2017 instead of 2019... in node_modules\gulp-msbuild\lib\msbuild-finder.js
line 14 (parameter list for the call to vswhere.exe)... change '-latest'
to '-version', '[15.0,16.0)'
from habitat.
Proposed solution: abandon gulp-msbuild in favor of msbuild (https://github.com/jhaker/nodejs-msbuild)
from habitat.
Instead of Gulp-Msbuild use the following
var _msBuild = require('msbuild');
var msbuild = new _msBuild();
The existing process loops through .csproj files however and builds them individually. If you switch to build on a .SLN level, project dependencies need to be configured.
Not necessarily saying this is a problem, just raising awareness :)
from habitat.
I have Visual Studio 2019 installed (and still VS17) and cannot reproduce this on the master
branch. The default buildToolsVersion
in the gulp-config
is 15.0
.
As announced at SUGCON, Habitat is being retired in favor of a new set of examples, which will likely be 100% MSBuild based with no use of gulp. So we do not plan on any significant changes to the gulp scripts at this time.
We will be doing a small maintenance release for Sitecore 9.2, so if there is an adjustment to the existing scripts that needs to happen that might be possible. Can you identify any additional differences between your scripts and the those on the master
branch?
from habitat.
Great to hear the sample will be gulp-free (fingers crossed it won't need NPM either), we've been considering trying to rid ourselves of Gulp once our hired Sitecore consultants hand off after go live.
When I ran into this I didn't notice any differences around how it calls gulp-msbuild, but I will try to make some time in the next day or 2 to revisit. Unfortunately my successful work-around involved modifying a line of code in gulp-msbuild, which is quite inconvenient since it's NPM-controlled.
from habitat.
Instead of Gulp-Msbuild use the following
var _msBuild = require('msbuild');
var msbuild = new _msBuild();
from habitat.
@hoquem1 that was my initial idea, but the trick is figuring out what else in gulpfile.js also needs to change.. it would be great if one was a drop-in replacement for the other, but it's not... at this point we're likely to try to convert it to straight-up msbuild, no node & no gulp... but not until the 3rd party consultants complete hand-off after go-live (we've got dev, qa, & uat, as well as blue-green with staging & prod, so the risk is relatively low
from habitat.
@af4jm take a look at this blog I created. Hopefully this will help you.
http://mohammadhoque.com/?p=296
from habitat.
@cassidydotdk
I didn't have to manually do that. It respected the dependency graph from solution file. Now that being said, just because I didn't run into an issue, I can't guarantee that it doesn't exists. I like the fact that someone else was thinking about the same issue as I was :)
from habitat.
Approach using require('msbuild')
from @cassidydotdk:
https://gist.github.com/cassidydotdk/d2c72096ee0a1b5cf1e542ee108ce024
from habitat.
This is resolved in v1.8 by switching to require('msbuild')
... thanks for the report and the suggested fixes everyone.
from habitat.
Related Issues (20)
- Issues with brand new install V9.1 with .NET 4.7.2
- To use static classes instead of structs for storing template GUIDs HOT 1
- Let Habitat be a starter kit HOT 8
- I do not find prerequisites.json in build/assets folder HOT 2
- Target framework is incorrect for Sitecore 9.1 in many/all modules' web.config HOT 1
- Running `GenerateSolrCertificate.ps1` returns PFX file cannot be found
- Site Selector Drop-Down does not show current site value correctly
- Habitat 1.7 support for Sitecore 9.1.1 ??? HOT 4
- Sitecore after Habitat setup admin login redirect to HTTP Error 404.0 - Not Found HOT 2
- Update for Sitecore 9.2 HOT 1
- Better handing of System.Buffers issue
- Field Editor ­ in Single line Text fields are dissapearing on save HOT 1
- Missing Documentation
- Settings.ps1 wrong IdentityServerUrl after merge
- Update Old Dates in content data HOT 3
- [Question] Reasoning about Foundation.Acount module HOT 3
- Foundation.Multisite 500 error on CD Habitat for Sitecore 9.1.0 HOT 1
- Database "core" not found on UserProfileProvider
- Change gulpfile.js file to support multiple solution files in root folder HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from habitat.