leiningen

N.B. The maintainers are on #leiningen on Libera chat IRC. Go there for direct support/bug reports.
Nick 2019-04-09T18:55:21.000800Z

In a leiningen plugin, can I see a list of which profiles have been enabled?

2019-04-09T20:14:01.001400Z

@nick.matthews if you just want to see from the cmd line, I think it’ll print if you use DEBUG=true lein ...

2019-04-09T20:14:18.002Z

if you are working on a plugin, you can get access to active profiles on the given project

Nick 2019-04-09T20:15:29.003400Z

working on making changes to an existing internal plugin, so trying to figure out how to access the activated plugins

2019-04-09T20:16:38.003800Z

leiningen.core.project/profile-annotations maybe can give you the info you want

2019-04-09T20:17:29.004300Z

this should return the :include-profiles of the project meta. I think that’s what you want, not the :active-profiles here. I forget what :active-profiles.

2019-04-09T20:26:30.004700Z

Well, I guess this sums it up somewhat https://github.com/technomancy/leiningen/commit/5893c1406aa41db473fac102a513812056016721

2019-04-09T20:26:58.005Z

so it depends on if you want pre-expanded or post-expanded when composites are involved

Nick 2019-04-09T20:44:46.005200Z

thanks, that’s helpful.

👍 1
Nick 2019-04-09T20:45:47.006400Z

Still trying to see if I can refactor this plugin such that I don’t have to apply magic to get the profiles to carry through to this stage. There’s a bunch of project file rewriting and reading going on.

2019-04-09T20:58:58.006600Z

Hmm