Hi everyone. I am trying to set up a development environment for Moodle Mobile 2. I followed the exact steps as mentioned in this page: https://docs.moodle.org/dev/Setting_up_your_development_environment_for_Moodle_Mobile_2
When I run npm run setup, I am getting many errors. Please find the attachment below.
Following are the steps I did:
1. Installed Git
2. Installed chromium
3. Installed nvm setup for windows (https://github.com/coreybutler/nvm-windows/releases)
4. npm cache clean --force
5. npm install -g cordova@8.1.2 ionic
npm WARN deprecated superagent@4.1.0: Please note that v5.0.1+ of superagent removes User-Agent header by default, therefore you may need to add it yourself (e.g. GitHub blocks requests without a User-Agent header). This notice will go away with v5.0.2+ once it is released.
C:\Program Files\nodejs\cordova -> C:\Program Files\nodejs\node_modules\cordova\bin\cordova
C:\Program Files\nodejs\ionic -> C:\Program Files\nodejs\node_modules\ionic\bin\ionic
+ ionic@5.4.6
+ cordova@8.1.2
added 834 packages from 577 contributors in 93.775s
6. npm install -g gulp
npm WARN deprecated fsevents@1.2.9: One of your dependencies needs to upgrade to fsevents v2: 1) Proper nodejs v10+ support 2) No more fetching binaries from AWS, smaller package size
C:\Program Files\nodejs\gulp -> C:\Program Files\nodejs\node_modules\gulp\bin\gulp.js
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules\gulp\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
7. npm install --global --production windows-build-tools (As administrator on cmd)
8. git clone https://github.com/moodlehq/moodlemobile2.git moodlemobiledirectory
9. cd moodlemobiledirectory
10. git checkout integration
11. npm run setup
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.11.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.11.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\sarat\AppData\Roaming\npm-cache\_logs\2019-11-21T05_16_46_759Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! moodlemobile@3.8.0 setup: `npm install && npx cordova prepare && npx gulp`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the moodlemobile@3.8.0 setup script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\sarat\AppData\Roaming\npm-cache\_logs\2019-11-21T05_16_46_973Z-debug.log
Thanks in Advance.