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-55348] Fix branch view and documentation #382

Merged

Conversation

quilicicf
Copy link
Contributor

@quilicicf quilicicf commented Jun 19, 2023

Goal of this PR (Original Issue)

Fix small mistakes with previous PR on naming strategies:

  • The branch and tag views were uglified by the previous PR on some SCM sources because they fill the name and display name with the same value. The current implementation of the code displays something like this in the branch view for these cases: master: master
  • The separator that was chosen : may not be the best option because it's already rather heavily used in the display names. Ex: on GitHub, it's frequent to use a commit message as the PR's title to benefit from squash & merge feature. Popular commit message templates tend to use colons which makes things hard to read. I switched to using - in this PR as it's done in the screenshot in the original issue because it looks better.
  • A user pointed out in the original issue's comments that the documentation for the display naming strategy didn't match the drop-down list's phrasing. I've fixed it, and added more documentation to help people link the behaviors with the enum values (for people using Job DSL)

Screenshot of the issue

image (1)

@quilicicf quilicicf requested a review from a team as a code owner June 19, 2023 12:58
@MathisGuillet1
Copy link

👍

@KalleOlaviNiemitalo
Copy link

KalleOlaviNiemitalo commented Jun 20, 2023

The branch and tag views were uglified by the previous PR on some SCM sources because they fill the name and display name with the same value.

Why would you add the "Job display name strategy" property to a branch source that does so?

… do you mean those SCM sources set the same string as name and display name for branches and tags, but two different strings for pull requests?

@quilicicf
Copy link
Contributor Author

… do you mean those SCM sources set the same string as name and display name for branches and tags, but two different strings for pull requests?

Exactly 🤷

@jglick jglick requested a review from jtnord June 26, 2023 13:29
@jglick
Copy link
Member

jglick commented Jun 26, 2023

@jtnord this is amending #374 IIUC?

@jtnord jtnord merged commit f1f275d into jenkinsci:master Jun 26, 2023
@quilicicf quilicicf deleted the master__JENKINS-55348_fixBranchView branch June 26, 2023 15:00
@quilicicf
Copy link
Contributor Author

Thanks guys 🙇

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

Successfully merging this pull request may close these issues.

6 participants