Skip to content

Commit

Permalink
ci: switch to using wevre/natural-compare (#597)
Browse files Browse the repository at this point in the history
The code I used was from a gist, probably more responsible to use a lib
that has clear license.
  • Loading branch information
lread authored Jun 21, 2024
1 parent c5054aa commit e4d3cc2
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 32 deletions.
3 changes: 2 additions & 1 deletion bb.edn
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
lread/status-line {:git/url "https://github.com/lread/status-line.git"
:sha "cf44c15f30ea3867227fa61ceb823e5e942c707f"}
dev.nubank/docopt {:mvn/version "0.6.1-fix7"}
org.babashka/http-server {:mvn/version "0.1.12"}}
org.babashka/http-server {:mvn/version "0.1.12"}
wevre/natural-compare {:mvn/version "0.0.8"}}
:tasks
{;; setup
:requires ([babashka.classpath :as cp]
Expand Down
28 changes: 0 additions & 28 deletions script/helper/natural_sort.clj

This file was deleted.

6 changes: 3 additions & 3 deletions script/test_matrix.clj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
[cheshire.core :as json]
[clojure.string :as string]
[doric.core :as doric]
[helper.natural-sort :as natural-sort]
[helper.main :as main]
[lread.status-line :as status]))
[lread.status-line :as status]
[wevre.natural-compare :as natural-compare]))

(defn- test-def [{:keys [os id platform browser jdk-version]}]
{:os os
Expand Down Expand Up @@ -77,7 +77,7 @@
(for [jdk-version (get os-jdks "ubuntu")
:when (not= jdk-version (:jdk-version default-opts))]
(test-doc {:jdk-version jdk-version :os "ubuntu"})))
(natural-sort/sort-by :desc)
(sort-by :desc natural-compare/natural-compare)
(into [(merge default-opts {:os "ubuntu" :cmd "bb lint" :desc "lint"})])
(mapv #(assoc % :id (string/replace (:desc %) " " "-"))))))

Expand Down

0 comments on commit e4d3cc2

Please sign in to comment.