Add start-dev command in Makefile

This commit is contained in:
Andrea Maria Piana 2018-03-13 11:55:42 +00:00 committed by Andrey Shovkoplyas
parent efa419b549
commit 972b5bbe24
No known key found for this signature in database
GPG Key ID: EAAB7C8622D860A4
1 changed files with 11 additions and 0 deletions

View File

@ -125,3 +125,14 @@ android-ports: ##@other Add reverse proxy to Android Device/Simulator
adb reverse tcp:8081 tcp:8081
adb reverse tcp:3449 tcp:3449
adb reverse tcp:4567 tcp:4567
startdev-%:
$(eval SYSTEM := $(word 2, $(subst -, , $@)))
$(eval DEVICE := $(word 3, $(subst -, , $@)))
if [[ "$(SYSTEM)" == "android" ]]; then\
${MAKE} prepare && ${MAKE} android-ports; \
else \
${MAKE} prepare-ios; \
fi
${MAKE} dev-$(SYSTEM)-$(DEVICE)
${MAKE} -j3 react-native repl-$(SYSTEM) run-$(SYSTEM)