Skip to content

Commit bb8abd0

Browse files
committed
trim trailing whitespace in generated system.edn (also tidy up "<% if %>" clauses
at head of file)
1 parent e4d268f commit bb8abd0

File tree

1 file changed

+14
-13
lines changed
  • libs/deps-template/resources/io/github/kit_clj/kit/resources

1 file changed

+14
-13
lines changed

libs/deps-template/resources/io/github/kit_clj/kit/resources/system.edn

+14-13
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@
99
<% if repl? %>
1010
:repl/server
1111
{:port #long #or [#env REPL_PORT 7200]
12-
:host #or [#env REPL_HOST "127.0.0.1"]}<% endif %> <% if nrepl? %>
12+
:host #or [#env REPL_HOST "127.0.0.1"]}<% endif %>
13+
<% if nrepl? %>
1314
:nrepl/server
1415
{:port #long #or [#env NREPL_PORT 7000]
1516
:bind #or [#env NREPL_HOST "127.0.0.1"]}<% endif %>
16-
<% if redis? %>
17+
<% if redis? %>
1718
:cache/redis
1819
{:ttl 3600
1920
:conn {:pool {}
@@ -25,8 +26,8 @@
2526
:handler #ig/ref :handler/ring}
2627

2728
:handler/ring
28-
{:router #ig/ref :router/core <% if metrics? %>
29-
:metrics #ig/ref :metrics/prometheus <% endif %>
29+
{:router #ig/ref :router/core<% if metrics? %>
30+
:metrics #ig/ref :metrics/prometheus<% endif %>
3031
:api-path "/api"
3132
:cookie-secret #or [#env COOKIE_SECRET "<<default-cookie-secret>>"]
3233
;; from ring.middleware.defaults. anti-forgery `false` by default because services may not require it
@@ -53,8 +54,8 @@
5354

5455
:reitit.routes/api
5556
{:base-path "/api"
56-
:env #ig/ref :system/env <% if metrics? %>
57-
:metrics #ig/ref :metrics/prometheus <% endif %><% if conman? %>
57+
:env #ig/ref :system/env<% if metrics? %>
58+
:metrics #ig/ref :metrics/prometheus<% endif %><% if conman? %>
5859
:query-fn #ig/ref :db.sql/query-fn<% endif %>
5960
}
6061

@@ -63,13 +64,13 @@
6364

6465
:router/core
6566
{:routes #ig/ref :router/routes
66-
:env #ig/ref :system/env} <% if quartz? %>
67+
:env #ig/ref :system/env}<% if quartz? %>
6768

6869
:cronut/scheduler
69-
{:schedule []}<% endif %> <% if selmer? %>
70+
{:schedule []}<% endif %><% if selmer? %>
7071

7172
:templating/selmer
72-
{}<% endif %> <% if xtdb? %>
73+
{}<% endif %><% if xtdb? %>
7374

7475
;; https://docs.xtdb.com/administration/configuring/
7576
:db.xtdb/node
@@ -84,7 +85,7 @@
8485
:db-dir "data/dev/index-store"
8586
:sync? true}}}
8687
:test {}
87-
:prod {}} <% endif %><% if hikari? %>
88+
:prod {}}<% endif %><% if hikari? %>
8889

8990
:db.sql/hikari-connection
9091
#profile {:dev {:jdbc-url "jdbc:mysql://127.0.0.1:3306/<<name>>?characterEncoding=utf8"}
@@ -102,7 +103,7 @@
102103
:password "123456"
103104
:jdbc-url #env JDBC_URL
104105
:driver-class-name "com.mysql.jdbc.Driver"
105-
:register-mbeans false}} <% endif %><% if conman? %>
106+
:register-mbeans false}}<% endif %><% if conman? %>
106107

107108
:db.sql/connection
108109
#profile {:dev {:jdbc-url "jdbc:postgresql://localhost/<<name>>?user=<<name>>&password=<<name>>"}
@@ -117,10 +118,10 @@
117118
{:conn #ig/ref :db.sql/connection
118119
:options {}
119120
:filename "queries.sql"
120-
:env #ig/ref :system/env} <% endif %><% if migratus? %>
121+
:env #ig/ref :system/env}<% endif %><% if migratus? %>
121122

122123
:db.sql/migrations
123124
{:store :database
124125
:db {:datasource #ig/ref :db.sql/connection}
125-
:migrate-on-init? true} <% endif %>
126+
:migrate-on-init? true}<% endif %>
126127
}

0 commit comments

Comments
 (0)