From 06a770cc38d34c9833b192a8585de066e52f5ea5 Mon Sep 17 00:00:00 2001 From: Miloslav Nenadal Date: Sat, 6 Jan 2024 08:46:55 +0100 Subject: [PATCH] Get rid of at.favre.lib/bytes dep --- deps.edn | 3 +-- src/build/util.clj | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/deps.edn b/deps.edn index 41f7f4a..f0b54e2 100644 --- a/deps.edn +++ b/deps.edn @@ -1,6 +1,5 @@ {:paths ["src" "test" "resources"] - :deps {at.favre.lib/bytes {:mvn/version "1.6.1"} - org.clojure/clojurescript {:mvn/version "1.11.60"} + :deps {org.clojure/clojurescript {:mvn/version "1.11.60"} reagent/reagent {:mvn/version "1.2.0"} re-frame/re-frame {:mvn/version "1.3.0"} metosin/jsonista {:mvn/version "0.3.7"} diff --git a/src/build/util.clj b/src/build/util.clj index 2cb8fd8..c21cc11 100644 --- a/src/build/util.clj +++ b/src/build/util.clj @@ -19,7 +19,7 @@ (defn- sha-1 [s] (let [c (java.security.MessageDigest/getInstance "sha-1")] (.update c (.getBytes s "utf-8")) - (.encodeHex (at.favre.lib.bytes.Bytes/wrap (.digest c))))) + (reduce (fn [s b] (str s (format "%02x" b))) "" (.digest c)))) (defn- file-hash [f] (-> f