Groups
Groups
Sign in
Groups
Groups
Jenkins Users
Conversations
About
Send feedback
Help
Need help with Shared Libraries in Jenkins
22 views
Skip to first unread message
Sanjiv Kumar
unread,
Apr 2, 2017, 3:22:41 PM
4/2/17
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Jenkins Users
Hi,
I am trying to implement a standard pipeline using Shared Libraries in Jenkins. I understand the directory structure for the same.
(root)
|
|----- src
|
|----- vars
|
|----- resources
I have declared variables in vars directory in groovy files. How I can access these variables in the groovy files src/com/xyz/a.groovy.
vars/b.groovy
import groovy.transform.Field
class Git {
@Field final Name = 'xyz'
}
return this;
I want to access the value of Name variable in src/com/xyz/a.groovy. Is it possible?
Any kind of help is highly appreciated.
Thanks,
Sanjiv
Reply all
Reply to author
Forward
0 new messages