refactor: use env-overridable ports via tmux-dev.env
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
{:deps {tmux-dev/tmux-dev {:git/url "https://gitea.florianschroedl.com/floscr/tmux-dev"
|
||||
:git/sha "3d9e53bc38b818bfcee312065ded0aef83bdecf4"}}
|
||||
:tasks
|
||||
{:requires ([tmux-dev.core :as td])
|
||||
:init (def dev-config {:session "atomsync-dev"
|
||||
:windows [["server" "bb server"]
|
||||
["cljs" "bb cljs:watch"]]
|
||||
:print ["App: http://localhost:8090"
|
||||
"Server: http://localhost:8090/sync"]})
|
||||
{:requires ([tmux-dev.core :as td] [tmux-dev.env :as env])
|
||||
:init (do (def port (env/number "PORT" 8090))
|
||||
(def dev-config {:session "atomsync-dev"
|
||||
:windows [["server" (str "bb server --port " port)]
|
||||
["cljs" "bb cljs:watch"]]
|
||||
:print [(str "App: http://localhost:" port)
|
||||
(str "Server: http://localhost:" port "/sync")]}))
|
||||
|
||||
server {:doc "Start the Atomsync sync server (serves example app)"
|
||||
:task (shell "clj" "-M:server" "--static-dir" "example/todomvc")}
|
||||
|
||||
Reference in New Issue
Block a user