()
| 6 | const { setupProject, installDeps } = require('./setup-project.js'); |
| 7 | |
| 8 | const createObytesApp = async () => { |
| 9 | consola.box('Obytes Starter\nPerfect React Native App Kickstart 🚀!'); |
| 10 | // get project name from command line |
| 11 | const projectName = process.argv[2]; |
| 12 | // check if project name is provided |
| 13 | if (!projectName) { |
| 14 | consola.error( |
| 15 | 'Please provide a name for your project: `npx create-obytes-app@latest <project-name>`' |
| 16 | ); |
| 17 | process.exit(1); |
| 18 | } |
| 19 | // clone the last release of the template from github |
| 20 | await cloneLastTemplateRelease(projectName); |
| 21 | |
| 22 | // setup the project: remove unnecessary files, update package.json infos, name and set version to 0.0.1 + add initial version to osMetadata |
| 23 | await setupProject(projectName); |
| 24 | |
| 25 | // install project dependencies using pnpm |
| 26 | await installDeps(projectName); |
| 27 | |
| 28 | // show instructions to run the project + link to the documentation |
| 29 | showMoreDetails(projectName); |
| 30 | }; |
| 31 | |
| 32 | createObytesApp(); |
no test coverage detected