This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-08-03
Channels
- # announcements (63)
- # asami (29)
- # beginners (23)
- # calva (23)
- # cider (18)
- # clj-kondo (12)
- # clojure (156)
- # clojure-europe (30)
- # clojure-italy (6)
- # clojure-nl (5)
- # clojure-uk (6)
- # clojurescript (14)
- # conjure (26)
- # cursive (8)
- # datalog (143)
- # datascript (1)
- # datomic (6)
- # duct (2)
- # emacs (50)
- # events (4)
- # figwheel-main (6)
- # fulcro (7)
- # graphql (12)
- # jobs (6)
- # malli (1)
- # mid-cities-meetup (2)
- # off-topic (4)
- # pathom (6)
- # portal (7)
- # re-frame (10)
- # reagent (8)
- # reitit (10)
- # releases (1)
- # reveal (18)
- # shadow-cljs (39)
- # sql (4)
- # tools-deps (36)
- # vim (25)
- # xtdb (6)
With the new :paths
alias data feature, I’m assuming that those aliases are just fished directly out of the :aliases
map in the (combined system/user/project) deps.edn map? i.e. there’s no alias selection done based on which aliases are passed by the user, or anything like that.
One further question: Cursive also shows aliases that the user can select in a tool window, which allows the user to decide which source paths etc should be synced to their project. I assume it doesn’t make sense to show these aliases there, i.e. it only makes sense to show those aliases whose value is a map.
Seems right
@cfleming That's my understanding based on playing with it a bit.
Thanks @seancorfield. It gets a little confusing in the case of :extra-paths
- those are calculated using the provided aliases, but then their alias values are taken from the raw map (I think).
In the latter question, aliases should be resolved from the merged edn map, same as paths. But maybe I’m not getting some nuance of your question
So using this map:
{:paths ["src" :clj-paths :resource-paths]
:aliases {:clj-paths ["src2"]
:resource-paths ["resources"]
:moar {:extra-paths ["src3" :moar-paths]}
:moar-paths ["src4"]}}
src, src2 and resources will always be selected. src3 and src4 will be selected if the user has chosen to use the moar alias.
@U064X3EF3 It feels like this is part of a bigger picture that we don't have all the pieces of -- since the alias references in ;paths
etc is all static at the moment, so you can't actually override any of it yet?
@seancorfield not sure what you mean about overriding
This is about giving names to sunsets of paths
One important place these names show up is in the classpath data in the basis
By "override" I meant that project aliases override user-level, and you can further override those on the command-line -- so I was thinking that you could provide a new :clj-paths
alias on the command-line to "override" a :clj-paths
alias in the project deps.edn
.
Like I say, I'm still not seeing much benefit in that feature yet, so I assume there's a "bigger picture" and it will make more sense "soon" 🙂
you could do all that but I do not have any use case in mind where that would be a good idea
better to manipulate with a -C alias modifying :extra-paths or overrides
Aye, and that's what I would tend to do -- so, again, I'm not seeing much benefit in being able to specify parts of paths etc as aliases right now.
then you should not do it :)
I guess you can supply new values via the command-line (`-Sdeps`) but I don't see much value in it as it stands.
I assume it's part of a bigger picture that we don't have all the pieces of yet...
Based on all the comments I guess it stands for “something” 😁
Btw, I have wondered how you prevent :)
turning into an emoticon. Is that a setting?