Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 5 additions & 18 deletions src/main/java/hudson/plugins/git/GitSCM.java
Original file line number Diff line number Diff line change
Expand Up @@ -1811,10 +1811,12 @@ public void setAllowSecondFetch(boolean allowSecondFetch) {
public void setAddGitTagAction(boolean addGitTagAction) { this.addGitTagAction = addGitTagAction; }

/**
* Old configuration of git executable - exposed so that we can
* migrate this setting to GitTool without deprecation warnings.
* @return git executable
* Old configuration of git executable, unused since 2023.
* Returns null in all cases.
* @deprecated use GitTool
* @return null
*/
@Deprecated(since = "5.11.0")
public String getOldGitExe() {
return null;
}
Expand Down Expand Up @@ -2166,21 +2168,6 @@ public boolean getDoGenerateSubmoduleConfigurations() {
return doGenerateSubmoduleConfigurations;
}

@Initializer(after=PLUGINS_STARTED)
public static void onLoaded() {
Jenkins jenkins = Jenkins.get();
DescriptorImpl desc = jenkins.getDescriptorByType(DescriptorImpl.class);

if (desc.getOldGitExe() != null) {
String exe = desc.getOldGitExe();
String defaultGit = GitTool.getDefaultInstallation().getGitExe();
if (exe.equals(defaultGit)) {
return;
}
System.err.println("[WARNING] you're using deprecated gitexe attribute to configure git plugin. Use Git installations");
}
}

@Initializer(before=JOB_LOADED)
public static void configureXtream() {
Run.XSTREAM.registerConverter(new ObjectIdConverter());
Expand Down
Loading