Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-28148] Whitespaces in toolLocations #28

Merged
merged 1 commit into from
Jul 27, 2015

Conversation

polopi
Copy link

@polopi polopi commented Apr 29, 2015

Use multiple values for toolLocations parameter instead of only one
with all tools, and splitting it by whitespace.
It allows to include whitespace in tool paths (cf windows)
Link to ticket: JENKINS-28148

⚠️ It is a breaking change !

The API of the CLI would now be :

-toolLocation tool1:location -toolLocation tool2:"a location"

Another options would be to change the separator of toolLocations. The semi-colon seems to be the best option for this. Leading to :

-toolLocations tool1:location;tool2:"a location"

Note that I tried to find some OptionHandler that would fit best, StringArrayOptionHandler for instance.

-toolLocations tool1:location "tool2:a location"

But it does not consider an option with quotes to be only one. Like current behaviour...

There is also the MapOptionHandler that would best fit the need IMO, but also requires to change the CLI API.

-toolLocation tool1=location -toolLocation tool2="a location"

I have implemented the first one the last one (see below) in this change.
Let me know which way do you prefer.

@jenkinsadmin
Copy link
Member

Thank you for a pull request! Please check this document for how the Jenkins project handles pull requests

@mrdfuse
Copy link
Contributor

mrdfuse commented Apr 30, 2015

I like the first and the last option the best. Which one exactly does your commit now support?

@polopi
Copy link
Author

polopi commented May 1, 2015

The first one, but I can change it to the last if the API is better

@polopi
Copy link
Author

polopi commented May 3, 2015

Additionnaly, this kind of API could be even simpler using the alias in Args4J :
-t toolName=location --toolLocation toolName=location
toolLocation being here the alias, and t the shortcut, because it's easier when having multiple tools.

Thus I'll change my commit to be this implementation for anyone to test.

Open to suggestions :)

@polopi polopi force-pushed the master branch 3 times, most recently from 8d6db11 to f92c396 Compare May 4, 2015 09:40
Use multiple values for toolLocations parameter instead of only one
parameters with all tools, and splitting by whitespace.
This allow to include whitespace in tool paths (cf windows)
Each tool need to be declared in a distinct option.
The API change to : -t toolName=path --toolLocation=path
@polopi
Copy link
Author

polopi commented May 16, 2015

Up

@mindjiver
Copy link
Contributor

Hi!

I'll be on vacation for about a week but I can take a look when I come back.

On Saturday, May 16, 2015, PaulP notifications@github.com wrote:

Up


Reply to this email directly or view it on GitHub
#28 (comment)
.

"It is often said that people who respect the importance of footwear are
the most successful, because they understand the value of working your way
up from the bottom."

@ololduck
Copy link

Hi!
Any updates on this? We are also impacted by this problem.

Thanks.

@mindjiver
Copy link
Contributor

Hi!

No time so far, tomorrow I'll take a look.

On Wednesday, June 17, 2015, Paul Ollivier notifications@github.com wrote:

Hi!
Any updates on this? We are also impacted by this problem.

Thanks.


Reply to this email directly or view it on GitHub
#28 (comment)
.

"It is often said that people who respect the importance of footwear are
the most successful, because they understand the value of working your way
up from the bottom."

@mindjiver
Copy link
Contributor

So, this is almost a month later and I feel bad. But vacations and general life got in between. I will try to set some time aside for this during this week.

@ololduck
Copy link

👍

@mindjiver
Copy link
Contributor

This looks alright but I think we should bump the major version since this is breaking the existing behaviour. So I would like to release the current version first (1.25). Then move on with this PR. Is that ok with you?

@polopi
Copy link
Author

polopi commented Jul 22, 2015

I'm ok with that 👍

@polopi polopi closed this Jul 22, 2015
@mindjiver
Copy link
Contributor

I'll pick this up after 1.26 has reached some users and any problems have been reported back! I think we can re-open this PR so I will not forget about it.

@polopi polopi reopened this Jul 23, 2015
mindjiver added a commit that referenced this pull request Jul 27, 2015
[JENKINS-28148] Whitespaces in toolLocations
@mindjiver mindjiver merged commit 355d1d2 into jenkinsci:master Jul 27, 2015
@mindjiver
Copy link
Contributor

I'll do some manual integration tests and then release version 2.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants