react native - deptno/deptno.github.io GitHub Wiki
react-native
react-native run ios --device "phonename"
์ค์
error
XXApp ์ผ๋ก ์ด๋ฆ ๊ฐ์
The operation couldnโt be completed. Unable to locate a Java Runtime.
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: ./gradlew app:installDefaultDebug -PreactNativeDevServerPort=8081
The operation couldnโt be completed. Unable to locate a Java Runtime.
Please visit http://www.java.com for information on installing Java.
-> ์๋ฐ ์ค์น
brew install --cask adoptopenjdk/openjdk/adoptopenjdk8
xcrun: error: unable to find utility "simctl", not a developer tool or in PATH
$ react-native run ios
info Found Xcode workspace "XXApp.xcworkspace"
xcrun: error: unable to find utility "simctl", not a developer tool or in PATH
error Could not get the simulator list from Xcode. Please open Xcode and try running project directly from there to resolve the remaining issues.
Error: Command failed: xcrun simctl list --json devices
xcrun: error: unable to find utility "simctl", not a developer tool or in PATH
at checkExecSyncError (node:child_process:826:11)
at Object.execFileSync (node:child_process:864:15)
at runOnSimulator (/[APP_PATH]/node_modules/@react-native-community/cli-platform-ios/build/commands/runIOS/index.js:167:54)
at Object.runIOS [as func] (/[APP_PATH]/node_modules/@react-native-community/cli-platform-ios/build/commands/runIS/index.js:121:12)
at Command.handleAction (/[APP_PATH]/node_modules/react-native/node_modules/@react-native-community/cli/build/index.js:192:23)
at Command.listener (/[APP_PATH]/node_modules/commander/index.js:315:8)
at Command.emit (node:events:390:28)
at Command.parseArgs (/[APP_PATH]/node_modules/commander/index.js:651:12)
at Command.parse (/[APP_PATH]/node_modules/commander/index.js:474:21)
at setupAndRun (/[APP_PATH]/node_modules/react-native/node_modules/@react-native-community/cli/build/index.js:271:24)
info Run CLI with --verbose flag for more details.
xcode-select -p
/Library/Developer/CommandLineTools
# ๊ฒฐ๊ณผ๊ฐ ์์ ๊ฐ์ ๊ฒฝ์ฐ ์๋ ์ปค๋งจ๋๋ฅผ ์
๋ ฅ
sudo xcode-select --switch /Applications/Xcode.app
error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code 65. To debug build logs further, consider building your app with Xcode.app, by opening XXApp.xcworkspace.
xcode ์์ ํ ์ค์ ํ์ error
Error: EMFILE: too many open files, watch
yarn dev 1 err 38s 11:33:15
โ Validation Warning:
Unknown option "server.enableVisualizer" with value true was found.
This is probably a typing mistake. Fixing it will remove this message.
###### ######
### #### #### ###
## ### ### ##
## #### ##
## #### ##
## ## ## ##
## ### ### ##
## ######################## ##
###### ### ### ######
### ## ## ## ## ###
### ## ### #### ### ## ###
## #### ######## #### ##
## ### ########## ### ##
## #### ######## #### ##
### ## ### #### ### ## ###
### ## ## ## ## ###
###### ### ### ######
## ######################## ##
## ### ### ##
## ## ## ##
## #### ##
## #### ##
## ### ### ##
### #### #### ###
###### ######
Welcome to React Native!
Learn once, write anywhere
node:events:368
throw er; // Unhandled 'error' event
^
Error: EMFILE: too many open files, watch
at FSEvent.FSWatcher._handle.onchange (node:internal/fs/watchers:204:21)
Emitted 'error' event on NodeWatcher instance at:
at NodeWatcher.checkedEmitError (/APP/node_modules/sane/src/node_watcher.js:143:12)
at FSWatcher.emit (node:events:390:28)
at FSEvent.FSWatcher._handle.onchange (node:internal/fs/watchers:210:12) {
errno: -24,
syscall: 'watch',
code: 'EMFILE',
filename: null
}
watchman ์ ์ค์นํ๋๋กํ๋ค.
์๋ฌ๋ ์ฌ๋ผ์ง์ง๋ง ๊ทผ๋ณธ์ ์ธ ์์ธ์ธ์ง๋ ๋ถ ๋ถ๋ช
ํ๋ค. ์ด์ ๋ vim์์๋ ๊ฐ์ ์๋ฌ๊ฐ ๋ฐ์ํ๋ค.
๊ทผ๋ณธ์ ์ผ๋ก๋ OS ์ค์ ์ผ ๊ฒ์ผ๋ก ๋ณด๋๋ฐ watchman ์ด ์ด๊ฑธ ์ด๋ป๊ฒ ์ฒ๋ฆฌํด์ผํ๋์ง๋ ์์๋ด์ผํ ๊ฒ ๊ฐ๋ค. @todo
sysctl ์ ํตํด์ ๋ณ์๋ฅผ ํ์ธํ ์ ์๋ค.
warning: Building targets in manual order is deprecated - choose Dependency Order in scheme settings instead, or set DISABLE_MANUAL_TARGET_ORDER_BUILD_WARNING in any of the targets in the current scheme to suppress this warning
schema edit -> build -> dependency order