How to programmatically get Jenkins Home from a plugin

21 views
Skip to first unread message

Samith Dassanayake

unread,
May 12, 2015, 12:50:01 AM5/12/15
to jenkin...@googlegroups.com
Hi all,
I want to get Jenkins Home in my java code of the plugin. How can I access it?

Thanks,
Samith

Adrien Lecharpentier

unread,
May 12, 2015, 1:37:55 AM5/12/15
to jenkin...@googlegroups.com
Hello,

I think you can use `Jenkins.getInstance().getRootDir()` to get a `java.io.File` of your JENKINS_HOME.

Best regards.
-- Adrien

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/d6f3a371-d3e8-45ac-9cdd-b307892fd3ae%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages