Add a dependency via command line ala pip and npm?


(David Feinberg) #1

After reading through the docs and doing some searches I haven’t found a way to add a dependency using the command line. Is this currently possible or does anybody know of a plugin that provides this functionality.

Coming from Python and JavaScript development I miss being able to quickly add a library using the command line (pip install or npm install). If nothing exists out there perhaps I could attempt to add this functionality. If so should it be a plugin or part of the existing CLI functionality?


(Stefan Oehme) #2

You could certainly do that in a plugin.

Personally I don’t see the benefit yet. Calling something like gradle addDep --gav junit:junit:4.12 --configuration compile seems more work to me than just opening my build file.