File tree Expand file tree Collapse file tree 6 files changed +47
-8
lines changed Expand file tree Collapse file tree 6 files changed +47
-8
lines changed Original file line number Diff line number Diff line change 1+ {:lint-as {honeysql.helpers/defhelper clj-kondo.lint-as/def-catch-all}}
Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on : [push]
4+
5+ jobs :
6+ build :
7+ runs-on : ubuntu-latest
8+ strategy :
9+ matrix :
10+ java : [ '8', '11', '14' ]
11+ name : For (java ${{ matrix.java }})
12+ steps :
13+ - uses : actions/checkout@v2
14+ - name : Setup Java
15+ uses : actions/setup-java@v1
16+ with :
17+ java-version : ${{ matrix.java }}
18+ - name : Setup Clojure
19+ uses : DeLaGuardo/setup-clojure@master
20+ with :
21+ tools-deps : ' 1.10.1.754'
22+ - name : Run tests (core)
23+ run : clojure -M:test:runner
24+ - name : Run tests (clojurescript)
25+ run : clojure -M:test:cljs-runner
26+ - name : Install clj-kondo
27+ run : |
28+ curl -sLO https://raw.githubusercontent.com/borkdude/clj-kondo/master/script/install-clj-kondo
29+ chmod +x install-clj-kondo
30+ sudo ./install-clj-kondo
31+ - name : Lint src
32+ run : clj-kondo --lint src/
33+ - name : Lint test
34+ run : clj-kondo --lint test/
35+ - name : Run cljfmt check
36+ run : clojure -Sdeps '{:deps {cljfmt {:mvn/version "0.7.0"}}}' -m cljfmt.main check
Original file line number Diff line number Diff line change @@ -8,3 +8,6 @@ pom.xml.asc
88/.nrepl-port
99.hgignore
1010.hg /
11+ .clj-kondo /.cache
12+ .lsp /
13+ cljs-test-runner-out /
Original file line number Diff line number Diff line change 1- # honeysql-postgres
2- [ ![ Clojars Project] ( https://img.shields.io/clojars/v/nilenso/honeysql-postgres.svg )] ( https://clojars.org/nilenso/honeysql-postgres ) [ ![ NPM Version] ( https://img.shields.io/npm/v/@honeysql/honeysql-postgres.svg )] ( https://www.npmjs.org/package/@honeysql/honeysql-postgres ) [ ![ cljdoc badge] ( https://cljdoc.org/badge/nilenso/honeysql-postgres )] ( https://cljdoc.org/d/nilenso/honeysql-postgres/CURRENT )
1+ # honeysql-postgres [ ![ Actions Status] ( https://github.com/nilenso/honeysql-postgres/workflows/CI/badge.svg )] ( https://github.com/nilenso/honeysql-postgres/actions ) [ ![ Clojars Project] ( https://img.shields.io/clojars/v/nilenso/honeysql-postgres.svg )] ( https://clojars.org/nilenso/honeysql-postgres ) [ ![ NPM Version] ( https://img.shields.io/npm/v/@honeysql/honeysql-postgres.svg )] ( https://www.npmjs.org/package/@honeysql/honeysql-postgres ) [ ![ cljdoc badge] ( https://cljdoc.org/badge/nilenso/honeysql-postgres )] ( https://cljdoc.org/d/nilenso/honeysql-postgres/CURRENT )
32
43PostgreSQL extensions for the widely used [ honeysql] ( https://github.com/jkk/honeysql ) .
54
Original file line number Diff line number Diff line change 124124 (str " WHERE " (sqlf/format-predicate* where))))))
125125
126126(defn- format-upsert-clause [upsert]
127- (let [ks (keys upsert)]
128- (map #(format-clause % (find upsert %)) upsert)))
127+ (map #(format-clause % (find upsert %)) upsert))
129128
130129(defmethod format-clause :upsert [[_ upsert] _]
131130 (sqlf/space-join (format-upsert-clause upsert)))
174173 (str
175174 ; ; if the select clause has any columns in it then add a comma before the
176175 ; ; window functions
177- (if (seq (:select complete-sql-map)) " , " )
176+ (when (seq (:select complete-sql-map)) " , " )
178177 (->> fields
179178 (map format-over-clause)
180179 sqlf/comma-join)))
232231 util/get-first
233232 sqlf/to-sql)))
234233
235- (defmethod format-clause :create-extension [[_ [ extension-name if-not-exists ]] _]
234+ (defmethod format-clause :create-extension [[_ [extension-name if-not-exists ]] _]
236235 (str " CREATE EXTENSION "
237236 (when if-not-exists " IF NOT EXISTS " )
238237 (-> extension-name
Original file line number Diff line number Diff line change 33 (:require [honeysql-postgres.format]
44 [honeysql.helpers :as sqlh #?(:clj :refer :cljs :refer-macros ) [defhelper ]]))
55
6- ; ; Extension of the honeysql helper funcitons for postgreSQL
6+ ; ; Extension of the honeysql helper functions for postgreSQL
77
8- (defn do-nothing [m]
8+ (defn do-nothing
99 " Accepts a map and append {:do-nothing []} to it"
10+ [m]
1011 (assoc m :do-nothing []))
1112
1213(defhelper do-update-set [m args]
You can’t perform that action at this time.
0 commit comments