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

Running selector on boolean build param #73

Open
bilki opened this issue Jan 4, 2022 · 0 comments
Open

Running selector on boolean build param #73

bilki opened this issue Jan 4, 2022 · 0 comments

Comments

@bilki
Copy link

bilki commented Jan 4, 2022

Which is the proper way to use selectors against boolean build params? I've tried this:

https://<jenkins_url>/badge/icon?subject=Boolean param ${params.myBoolean}&build=last,-10,lastCompleted:${params.myBoolean=true}

As the params.myBoolean in the subject spits true or false, I assumed that I could use that same string in the selector, but it doesn't seem to be working correctly (selector evaluation is defaulting to true).

I imagine that https://github.com/jenkinsci/embeddable-build-status-plugin/blob/master/src/main/java/org/jenkinsci/plugins/badge/extensions/BuildParameterRunSelectorExtension.java#L41 this line is where the evaluation is taking place, but I can't see anything wrong with that, unless value.getValue().toString() is doing something completely different from what I think 🤔

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

No branches or pull requests

1 participant