summaryrefslogtreecommitdiff
path: root/resources
diff options
context:
space:
mode:
authorAsko Nõmm <asko@nmm.ee>2025-09-25 21:39:10 +0300
committerAsko Nõmm <asko@nmm.ee>2025-09-25 21:39:10 +0300
commitcf55a6a6688c54527a3d27a8d6027858ced99257 (patch)
tree482723e4e51bbd02563ebd9bd6630c87ff36b2a4 /resources
parent3714b9c97609adc2b48b66c293259a0b5c3eddf6 (diff)
Rename utils to templates, as it is more appropriate.
Diffstat (limited to 'resources')
-rw-r--r--resources/clj-kondo/config.edn4
-rw-r--r--resources/clj-kondo/hooks/dompa.clj13
2 files changed, 9 insertions, 8 deletions
diff --git a/resources/clj-kondo/config.edn b/resources/clj-kondo/config.edn
index fa8d235..813976f 100644
--- a/resources/clj-kondo/config.edn
+++ b/resources/clj-kondo/config.edn
@@ -1,2 +1,2 @@
-{:hooks {:analyze-call {dompa.utils/$ hooks.dompa/$}}
- :linters {:dompa.utils/$-arg-validation {:level :warning}}} \ No newline at end of file
+{:hooks {:analyze-call {dompa.templates/$ hooks.dompa/$}}
+ :linters {:dompa.templates/$-arg-validation {:level :warning}}} \ No newline at end of file
diff --git a/resources/clj-kondo/hooks/dompa.clj b/resources/clj-kondo/hooks/dompa.clj
index fb3b823..0db709f 100644
--- a/resources/clj-kondo/hooks/dompa.clj
+++ b/resources/clj-kondo/hooks/dompa.clj
@@ -19,8 +19,9 @@
(api/reg-finding!
(assoc (meta invalid-arg)
:message (str "Invalid argument type. When creating a text node, "
- "only literal values (strings, numbers and symbols) are allowed.")
- :type :dompa.utils/$-arg-validation)))))
+ "only literal values (strings, numbers and symbols) "
+ "are allowed.")
+ :type :dompa.templates/$-arg-validation)))))
; if the first arg is a keyword, then the second argument can only be
; a sequence or a map.
@@ -34,10 +35,10 @@
"the second argument must be a sequence or a map. "
"In other words, the second argument must be an attribute map "
"or sequence of other nodes created with the $ macro.")
- :type :dompa.utils/$-arg-validation))
+ :type :dompa.templates/$-arg-validation))
; if the first arg is a keyword, the second arg is a list, then
- ; every arg has to be a list.
+ ; every arg has to be a list node.
(and (api/keyword-node? first-arg)
(api/list-node? (first rest-args))
(not (every? #(api/list-node? %) (rest rest-args))))
@@ -47,7 +48,7 @@
(assoc (meta arg)
:message (str "Invalid argument type. Argument has to be a $ macro "
"or a sequence of $ macros.")
- :type :dompa.utils/$-arg-validation))))
+ :type :dompa.templates/$-arg-validation))))
; if the first arg is a keyword, the second arg is a map, then from
; the second forwards everything has to be a list node
@@ -59,4 +60,4 @@
:message (str "Invalid argument type. When having a attribute map, "
"the rest of the arguments must be a $ macro or a sequence "
"of $ macros")
- :type :dompa.utils/$-arg-validation)))))
+ :type :dompa.templates/$-arg-validation)))))