Rapid-fire: how do you list installed plugins and their versions?
BeginnerConceptBest practices & rapid-fire commands
Answer
curl -s -u admin:$TOKEN "https://jenkins/pluginManager/api/json?depth=1&tree=plugins[shortName,version]" \
| jq -r '.plugins[] | "\(.shortName):\(.version)"' | sort
java -jar jenkins-cli.jar -s https://jenkins/ -auth admin:$TOKEN list-plugins
The first command's output is a valid plugins.txt.
More on Best practices & rapid-fire commands
What are the top Jenkinsfile best practices you follow?IntermediateWhat are the top controller best practices?IntermediateRapid-fire: how do you get the initial admin password?BeginnerRapid-fire: how do you trigger a parameterized build with curl and follow it?BeginnerRapid-fire: how do you run the controller in Docker for a quick test?BeginnerRapid-fire: how do you connect an inbound agent with Docker?Beginner