This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-04-03
Channels
- # aws (5)
- # beginners (67)
- # boot (30)
- # cider (55)
- # clara (7)
- # cljs-dev (6)
- # cljsjs (6)
- # cljsrn (1)
- # clojure (136)
- # clojure-brasil (2)
- # clojure-dusseldorf (14)
- # clojure-finland (9)
- # clojure-italy (49)
- # clojure-nl (1)
- # clojure-romania (6)
- # clojure-russia (4)
- # clojure-uk (16)
- # clojurescript (136)
- # core-async (1)
- # cursive (21)
- # datomic (64)
- # fulcro (26)
- # hoplon (25)
- # jobs-discuss (53)
- # keechma (3)
- # leiningen (6)
- # luminus (11)
- # lumo (2)
- # off-topic (351)
- # om (1)
- # onyx (11)
- # parinfer (32)
- # portkey (9)
- # re-frame (45)
- # reagent (38)
- # shadow-cljs (60)
- # specter (9)
- # vim (8)
- # yada (22)
hi folks, looking for a few pointers regarding: https://github.com/luminus-framework/boot-migratus
after setting up my config in build.boot
, I can run (boot (migratus :command "create" :options "ok"))
in REPL and the task runs
I have dug around in the boot documentation on filesets and tasks, and I am still pretty unclear as to how to get the task to sync the migration to my project rather than boot's ephemeral fs
migratus {:config
(fn []
(require '[creader.config])
(let [connection (resolve 'creader.config/migration-connection)
load-config (resolve 'creader.config/load-config)
load-profile (resolve 'creader.config/load-profile)]
(println "conn: " connection)
(println "load-config: " load-config)
(println "load-profile: " load-profile)
(println "config: " (load-config (load-profile)))
(println "conn: " (connection (load-config (load-profile))))
(connection (load-config (load-profile)))))}
boot.user> (boot (migratus :command "create" :options "ok"))
conn: #'creader.config/migration-connection
load-config: #'creader.config/load-config
load-profile: #'creader.config/load-profile
config: {:webserver {:port 3000}, :db {:password nil, :classname org.postgresql.Driver, :hostname localhost, :subprotocol postgresql, :database creader_dev, :init-script init-dev.sql, :migration-table-name schema_version, :user nil, :subname creader_dev}}
conn: {:store :database, :migration-dir migrations/, :init-script init-dev.sql, :init-in-transaction? false, :migration-table-name schema_version, :db {:classname org.postgresql.Driver, :subprotocol postgresql, :subname creader_dev}}
nil