Since git deps are checked out before being used, could clj -X:deps prep also work on them?
Yes, it does
Perhaps a dumb question, but is it possible to run a tool without installing it first? I’m imagining something like this:
clojure -Ttools run nvd-clojure/nvd-clojure '{:mvn/version "3.4.0"}' nvd.task/check
This is for CI/scripting, where I’d prefer not to have a separate install step from running the toolYeah, that might be an option, I’ll take a look
Named tools are installed by definition
You can use a tool alias though
Do you need -T or just -X?
If you want to both install and run, that’s going to be two commands
I want to run https://github.com/namenu/deps-diff, without using the content of my deps.edn file in the classpath, so I think as -T?
@danielcompton There's no entry point to run that via -T or -X with paths to EDN files. It has a GH action that invokes the CLI twice to produce deps trees and then compares those as EDN: https://github.com/namenu/deps-diff/blob/main/action.yml#L64-L89
(I mean, yes, there's a -X entrypoint the action uses but you need to run two CLI commands first to prep the data)
Yup, I need to fork it to get it to run its own diff as a tool. Currently, it is running as clojure -Sdeps which means that everything in the deps.edn is also included in the classpath, which is causing issues in our case
The other issue with installing as a tool in a GitHub action is that the author of the GitHub action needs to pick a name that doesn’t collide with the names of tools that any consumers have installed. So I guess you should just pick a long unique name?
Can you use :deps in the alias to replace the deps?