Closed r0b0t3d closed 3 years ago
@pmadruga @r0b0t3d hey guys. thank you for your work on react-native-clean-project! i am a new user and the cli is failing for me because of this issue. any update on this matter?
@Domeee just try my branch to see if it works for you
yarn add -D https://github.com/r0b0t3d/react-native-clean-project.git
@r0b0t3d Thank you. Here are the results:
Besides those two findings, the cli ran without problems.
npx react-native clean-project
[INSERT] [develop] Wipe iOS build folder? (Y/n) n
Wipe iOS Pods folder? (Y/n) n
Wipe system iOS Pods cache? (Y/n) n
Wipe user iOS Pods cache? (Y/n) n
Update pods? (Y/n) n
Wipe android build folder? (Y/n) y
🚫 Please select 'Y' for yes, or 'n' for no.
Wipe android build folder? (Y/n) y
🚫 Please select 'Y' for yes, or 'n' for no.
Wipe android build folder? (Y/n) Y
Clean Android project? (Y/n) y
🚫 Please select 'Y' for yes, or 'n' for no.
Clean Android project? (Y/n) Y
Wipe node_modules folder? (Y/n) y
🚫 Please select 'Y' for yes, or 'n' for no.
Wipe node_modules folder? (Y/n) Y
Update brew? (Y/n) n
✅ wipe android build folder task has finished running in 37ms.
✅ watchman cache clear (if watchman is installed) task has finished running in 29ms.
✅ wipe temporary caches task has finished running in 22ms.
✅ wipe node_modules task has finished running in 1s.
✅ yarn cache clean (if yarn is installed) task has finished running in 4ms.
✅ npm cache verify task has finished running in 44s.
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated deep-assign@3.0.0: Check out `lodash.merge` or `merge-options` instead.
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated sane@4.1.0: some dependency vulnerabilities fixed, support for node < 10 dropped, and newer ECMAScript syntax/features added
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
Error running 'npm ci': npm
Error running 'npm ci': WARN deprecated uglify-es@3.3.9: support for ECMAScript is superseded by `uglify-js` as of v3.13.0
✅ npm ci task has finished running in 7s.
✅ yarn install (if yarn is installed) task has finished running in 4ms.
✅ clean android project task has finished running in 4s.
Issue
Error running 'clean android project': Could not read script '/node_modules/@react-native-community/cli-platform-android/native_modules.gradle' as it does not exist.
Root cause
If
Wipe node_modules folder?
isYes
,node_module
will be deletedSolution
Make sure to execute
cleanAndroidProject
task afteryarnInstall