Moodle for mobile

Current working directory is not a Cordova-based project.

 
Picture of Kehinde Adeoya
Current working directory is not a Cordova-based project.
 

I have cloned the repo on my system and trying to build so as to customize splash screen and the rest. I am in the root directory of the mobile app, and after running this command from the root directory (moodlemobile2) I got this error as displayed below. Please help.

<i>Kehindes-MacBook-Pro:moodlemobile2 kehindeadeoya$ npm run setup

> moodlemobile@3.5.1 setup /Users/kehindeadeoya/Documents/moodlemobile2
> npm install && cordova prepare && gulp

npm WARN electron-builder-squirrel-windows@20.19.0 requires a peer of electron-builder-lib@~20.19.0 but none is installed. You must install peer dependencies yourself.

audited 8991 packages in 29.832s
found 5 moderate severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details
Current working directory is not a Cordova-based project.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! moodlemobile@3.5.1 setup: `npm install && cordova prepare && gulp`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the moodlemobile@3.5.1 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!     /Users/kehindeadeoya/.npm/_logs/2018-10-08T09_43_18_848Z-debug.log
Kehindes-MacBook-Pro:moodlemobile2 kehindeadeoya$ </i>


 
Average of ratings: -
Picture of Michelle Melton
Re: Current working directory is not a Cordova-based project.
Core developersPlugin developers

I encountered this same error and came across this Tracker issue which resolved my issue:

https://tracker.moodle.org/browse/MOBILE-2593

 
Average of ratings: -
Picture of Dani Palou
Re: Current working directory is not a Cordova-based project.
Core developersMoodle HQParticularly helpful MoodlersPlugin developers

Hi,

if the project doesn't have a folder called "www", please create it manually. That should fix the issue.

Kind regards,

Dani

 
Average of ratings: -