-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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-68030] Optionally report most recent commit as changelog of a new build #1565
Conversation
Consider updating the references to "changelog" in documentation to "changeset" to match the keyword used in Jenkinsfiles. |
src/main/java/jenkins/plugins/git/traits/FirstBuildChangelogTrait.java
Outdated
Show resolved
Hide resolved
// this is the first time we are building this branch, so there's no base line | ||
// to compare against. | ||
// if we force the changelog, it'll contain all the changes in the repo, which | ||
// is not what we want. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this existing comment should be rewritten now that its within the context of the else case of the new option. But, perhaps just removing it would be best.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed in 61bb758
src/main/java/jenkins/plugins/git/traits/FirstBuildChangelogTrait.java
Outdated
Show resolved
Hide resolved
Co-authored-by: UltimateGeek <10050028+UltimateGeek@users.noreply.github.com>
Removed improper CloudBees copyright documentation, updated @param for the constructor
I have seen this issue in other pull requests (#1556 (comment)) I was wondering if anyone had other insight into this issue of not passing the windows tests? |
Use line termination that is consistent with the other files in the repository. Use import ordering as defined by spotless.
src/main/java/hudson/plugins/git/extensions/impl/FirstBuildChangelog.java
Outdated
Show resolved
Hide resolved
src/main/resources/hudson/plugins/git/extensions/impl/FirstBuildChangelog/config.groovy
Outdated
Show resolved
Hide resolved
src/main/java/hudson/plugins/git/extensions/impl/FirstBuildChangelog.java
Show resolved
Hide resolved
Needs documentation added to the README that describes how this is used in a Pipeline and how it is displayed to the user when they use the Pipeline snippet syntax generator inside their Jenkins controller. I created a Pipeline with the Pipeline snippet syntax generator like this:
|
The new extension reports the most recent commit as the changelog. It does not report the changes from a base branch, because there is no reliable method to identify the base branch from command line git. Also adjusts capitalization to be consistent with other parts of the documentation.
Thanks for asking. I needed to make several changes to prepare for a final code review and interactive testing.
Interactive tests are needed to confirm there are no surprises that automation has missed. |
Thanks @MarkEWaite . I see the checklist item for the online help updates is still outstanding. Are there any changes with it you'd like @rhit-gawronja or @rhit-inskeeda to make? |
I've completed the changes in the online help and in the documentation. I don't see any further changes that are needed. |
Hi @MarkEWaite , do you have an estimate on when this will be ready to merge? |
I do not. I'm deeply involved in the Spring Security 6.x upgrade and in the preparations for the transition to require Java 17. A release will probably be needed as part of that, but I don't have a timeline for that next release. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ready to merge.
Incremental that includes: * Use poll env when checking for ls-remote branches jenkinsci/git-plugin#1511 * Optionally report the most recent commit as the changelog of a new build jenkinsci/git-plugin#1565 https://issues.jenkins.io/browse/JENKINS-4162 https://issues.jenkins.io/browse/JENKINS-14138 https://issues.jenkins.io/browse/JENKINS-26354 https://issues.jenkins.io/browse/JENKINS-68030 * Generate and revoke access tokens with standard UI components jenkinsci/git-plugin#1597 * Do not assume HttpResponse is a functional interface jenkinsci/git-plugin#1590
JENKINS-68030 - Optionally report the most recent commit as the changelog of a new build
Looking to fix the behavior that is associated with push changes onto a brand new created branch. With these changes when the behavior is selected Jenkins will now present a changelog on the creation of a new branch. The changelog for the first build will be the most recent commit on the branch.
Other issue reports that are related and highlight the complexity of the general case include:
Git doesn't have the concept of a base branch. Many SCM providers (GitHub, Bitbucket, GitLab, Gitea, etc.) have a concept of a target branch, but the git plugin intentionally limits itself to the capabilities provided by command line git. Other plugins (like the GitHub branch source, Bitbucket branch source, GitLab branch source, and Gitea plugins) provide more capabilities and implement those capabilities using the specific APIs of the SCM provider.
Checklist
Types of changes
What types of changes does your code introduce?