From 951395d4fb795c8e633374e9a9f28e02e7499e90 Mon Sep 17 00:00:00 2001 From: Dmitry Novotochinov Date: Wed, 8 Aug 2018 18:49:16 +0300 Subject: [PATCH] Add --start-bundler option --- src/clj_rn/core.clj | 5 +++-- src/clj_rn/main.clj | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/clj_rn/core.clj b/src/clj_rn/core.clj index f7ca909..4160878 100644 --- a/src/clj_rn/core.clj +++ b/src/clj_rn/core.clj @@ -198,7 +198,7 @@ (System/exit 1))) (defn watch - [{:keys [build-ids android-device ios-device start-figwheel start-app start-cljs-repl]}] + [{:keys [build-ids android-device ios-device start-figwheel start-app start-cljs-repl start-bundler]}] (let [{:keys [figwheel-options builds] :as config} (get-main-config) hosts-map {:android (resolve-dev-host :android android-device) :ios (resolve-dev-host :ios ios-device)}] @@ -206,7 +206,8 @@ (enable-source-maps) (write-env-dev hosts-map) (rebuild-index-files build-ids hosts-map) - (execute-react-native-cli ["start"] true) + (when start-bundler + (execute-react-native-cli ["start"] true)) (when start-figwheel (ra/start-figwheel! {:build-ids build-ids diff --git a/src/clj_rn/main.clj b/src/clj_rn/main.clj index afdc26c..8c571a0 100644 --- a/src/clj_rn/main.clj +++ b/src/clj_rn/main.clj @@ -103,7 +103,8 @@ (with-common-options [[nil "--[no-]start-app" "Start `react-native run-*` or not" :default true] [nil "--[no-]start-figwheel" "Start Figwheel or not" :default true] - [nil "--[no-]start-cljs-repl" "Start cljs repl or not" :default true]])) + [nil "--[no-]start-cljs-repl" "Start cljs repl or not" :default true] + [nil "--[no-]start-bundler" "Start RN bundler or not" :default true]])) (defmethod task :watch [[_ & args]] (let [options (parse-cli-options args watch-task-options)]