This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-09-02
Channels
- # aleph (25)
- # announcements (17)
- # aws (2)
- # babashka (72)
- # beginners (44)
- # calva (6)
- # cider (3)
- # clj-kondo (109)
- # cljfx (1)
- # cljsrn (31)
- # clojure (151)
- # clojure-austin (1)
- # clojure-europe (36)
- # clojure-nl (5)
- # clojure-norway (2)
- # clojure-spec (17)
- # clojure-uk (12)
- # clojurescript (74)
- # cursive (57)
- # data-science (1)
- # datascript (28)
- # datomic (40)
- # depstar (15)
- # gratitude (3)
- # helix (3)
- # introduce-yourself (1)
- # joker (1)
- # kaocha (2)
- # leiningen (2)
- # lsp (70)
- # lumo (2)
- # malli (2)
- # meander (4)
- # off-topic (10)
- # polylith (27)
- # quil (4)
- # re-frame (18)
- # reagent (24)
- # ring (4)
- # rum (1)
- # shadow-cljs (102)
- # sql (2)
- # tools-deps (48)
- # web-security (8)
- # xtdb (5)
Hi Sean, I’ve followed your adviced and implemented the aliases property
clojure '{:mvn/local-repo ".m2"}' -X:uberjar :classpath '"'$(clojure -Sdeps '{:mvn/local-repo ".m2"}' -Spath -A:prod)'"'
but i got these error
WARNING: Implicit use of clojure.main with options is deprecated, use -M
Execution error (FileNotFoundException) at java.io.FileInputStream/open0 (FileInputStream.java:-2).
{:mvn/local-repo ".m2"} (No such file or directory)
all deps were downloaded
(at lease I see ton of
Downloading: org/clojure/core.async/1.3.610/core.async-1.3.610.jar from central
Please advice what i am doing wrongclojure
treats the first non-option argument as a script to run. Did you mean -Sdeps
in there @kirill.salykin?
Oh, indeed. Thank you!
Why not just
clojure -Sdeps '{:mvn/local-repo ".m2"}' -X:uberjar :aliases '[:prod]'
As I understand aliases will not save deps into local .m2 folder
Or use deps from local .m2
Why do you want the deps in a different folder? What's the scenario?
It is gitlab ci, i have a separate step to fetch all deps so other steps shouls jot be concerned about it
Ans gitlav ci has some issues with not local folders
(Local to repo)
I am not recall exactly, but afaik it cant use non local dirsr as artefacta or cache
Seems unlikely that it can't cache the standard Maven local repo location -- every single CI I've used can do that.
maybe something is changed now - but afaik the cached folder should be local to the project dir first found link also uses this approach https://medium.com/devops-with-valentine/caching-maven-dependencies-in-a-gitlab-ci-pipeline-c50017085a2 dunno exact reasons (maybe not the case anymore)
OK, so, yeah, in that case you will need:
clojure -Sdeps '{:mvn/local-repo ".m2"}' -X:uberjar :classpath '"'$(clojure -Sdeps '{:mvn/local-repo ".m2"}' -Spath -A:prod)'"'
so that both depstar
's deps and your project's deps are downloaded to that local .m2
folder.Roger that, thanks a lot for helping!