How to set Jenkins environment variables containing spaces?

1,171 views
Skip to first unread message

nada abdelkader

unread,
Jan 12, 2017, 9:07:48 AM1/12/17
to Jenkins Users
Hello,

I have some env variables to configure (Jenkins->manage Jenkins->configure System -> Global properties -> Environment variables) in Jenkins (1.632) which take a list of values.

I know that I have to list the values in the value field but what I need to know is if one of these values contains already spaces, what should I do?
For example:
my variable name: MY_VAR
my values: vaule 1, value 2, value 3,...

thks 

Victor Martinez

unread,
Jan 14, 2017, 12:59:09 PM1/14/17
to Jenkins Users
If you ask how to search spaces in a particular string then this is not the right mailing list to ask for and there are plenty of information on internet about parsing/grepping/searching spaces in strings, such as:


Otherwise, I didn't understand exactly your question though.

Cheers

nada abdelkader

unread,
Jan 16, 2017, 8:40:03 AM1/16/17
to Jenkins Users
Thks for your answer, but that's not what I am looking for.

I'm trying to set an environment var on Jenkins that can have many values. I'm looking for a separator (other than white space) to set these values (Jenkins->manage Jenkins->configure System -> Global properties -> Environment variables), because some of my values have spaces.

Slide

unread,
Jan 16, 2017, 10:03:37 AM1/16/17
to Jenkins Users

Did you try putting those values in quotes?


--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/fa5a6594-e6af-4824-bf24-0339d00320db%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages