This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-03-12
Channels
- # announcements (19)
- # babashka (33)
- # beginners (96)
- # bitcoin (6)
- # cider (11)
- # circleci (5)
- # clj-kondo (22)
- # cljs-dev (4)
- # cljsjs (2)
- # clojure (65)
- # clojure-australia (9)
- # clojure-berlin (1)
- # clojure-europe (53)
- # clojure-italy (2)
- # clojure-nl (2)
- # clojure-uk (42)
- # clojurescript (9)
- # conjure (1)
- # cursive (33)
- # data-oriented-programming (1)
- # data-science (6)
- # datomic (12)
- # emacs (12)
- # fulcro (7)
- # graphql (4)
- # honeysql (5)
- # jobs (2)
- # juxt (8)
- # lsp (30)
- # malli (9)
- # off-topic (9)
- # other-languages (1)
- # re-frame (17)
- # reagent (11)
- # reitit (5)
- # releases (2)
- # remote-jobs (3)
- # shadow-cljs (39)
- # spacemacs (6)
- # sql (2)
- # testing (3)
- # tools-deps (43)
- # vim (5)
- # xtdb (11)
@souenzzo That wouldn't work for code that expects to read files (from the current directory).
(and it's only stuff like src
/`test`/`resources` that are relative in path?)
@seancorfield i understand that limitation, but I still think that this transformation is useful
currently all deps looks canonical, only the :paths
items (src resources) are "relative"
Here's a trick to add the :paths
to the path as canonical versions:
clojure -Sdeps '{:deps {my/app {:local/root "."}}}' -Spath
You'll still get src
etc but you'll also get them as full paths.
clojure -Sdeps '{:deps {my/app {:local/root "."}}}' -Spath | tr ':' '\n'
src
resources
service
😞It's not quite what you want but it seems like a good workaround...?
If you want to file a question on ask.Clojure I can track it there
@souenzzo what version of the CLI are you using? That's not what I see when I run that.
Hmm,
seanc@DESKTOP-30ICA76:~/oss/honeysql$ clojure -Spath | tr : '\n'
src
/home/seanc/.m2/repository/org/clojure/clojure/1.9.0/clojure-1.9.0.jar
/home/seanc/.m2/repository/org/clojure/core.specs.alpha/0.1.24/core.specs.alpha-0.1.24.jar
/home/seanc/.m2/repository/org/clojure/spec.alpha/0.1.143/spec.alpha-0.1.143.jar
seanc@DESKTOP-30ICA76:~/oss/honeysql$ clojure -Sdeps '{:deps {my/lib {:local/root "."}}}' -Spath | tr : '\n'
src
/home/seanc/oss/honeysql/src
/home/seanc/.m2/repository/org/clojure/clojure/1.9.0/clojure-1.9.0.jar
/home/seanc/.m2/repository/org/clojure/core.specs.alpha/0.1.24/core.specs.alpha-0.1.24.jar
/home/seanc/.m2/repository/org/clojure/spec.alpha/0.1.143/spec.alpha-0.1.143.jar
Thanks! Good to know
anyone else here with feedback on the CLI prereleases that shell out to git?
latest is 1.10.3.810
Nuked rm -rf ~/.gitlibs after installing 1.10.3.810 Seems to be downloading everything correctly when building projects. (macOS Big Sur)
:thumbsup: thx
Worked fine in my basic tests, but I don’t have too many git deps. Vendored 1.10.3.810 into the repo at work and everything still works in our dev/test/build pipeline (only one git dep there though, on Cognitect’s test-runner).
@alexmiller hrm in work project if I change the sha it says it can't resolve
Checking out: [email protected]:vouch-opensource/krell.git at 54944e3ef361d9d5e3ac6b6f63dd84713ef9db07
Error building classpath. Unable to checkout 54944e3ef361d9d5e3ac6b6f63dd84713ef9db07
fatal: invalid reference: 54944e3ef361d9d5e3ac6b6f63dd84713ef9db07
what version are you using?
1.10.2.801 was definitely broken when using multiple shas from the same repo, but that was fixed in 1.10.2.805 and latest 1.10.3.810
but what that sounds like as I think about it more is a missed fetch - trying to resolve using a new sha that has been created since the initial clone
I'll see if I can repro
@dnolen bug found, and fixed, new release in the works, thx
Clojure CLI prerelease 1.10.3.814 is now available: • fix issue with detecting when git fetch is needed for git deps
tools.gitlibs is now so "pure Clojure" because of the shelling out, that it can be run with babashka from source :)
$ bb -cp src/main/clojure -e "(require '[clojure.tools.gitlibs :as gl]) (gl/procure \"\" 'org.clojure/tools.gitlibs \"11fc77496f013871c8af3514bbba03de0af28061\")"
Cloning:
Checking out: at 11fc77496f013871c8af3514bbba03de0af28061
"/Users/borkdude/.gitlibs/libs/org.clojure/tools.gitlibs/11fc77496f013871c8af3514bbba03de0af28061"
(second time: 37ms)