Skip to content

Commit

Permalink
Removed a few defunct Gradle Settings
Browse files Browse the repository at this point in the history
  • Loading branch information
lkishalmi committed Oct 3, 2023
1 parent f6e7fe3 commit 86da2eb
Show file tree
Hide file tree
Showing 9 changed files with 125 additions and 177 deletions.
15 changes: 15 additions & 0 deletions extide/gradle/apichanges.xml
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,21 @@ is the proper place.
<!-- ACTUAL CHANGES BEGIN HERE: -->

<changes>
<change id="gradle-setting-deprecation">
<api name="general"/>
<summary>Some Gradle Settings Removed from Use</summary>
<version major="2" minor="36"/>
<date day="2" month="10" year="2023"/>
<author login="lkishalmi"/>
<compatibility semantic="compatible" />
<description>
<p>
Setting the following properties: <code>startDaemonOnStart</code>, <code>silentInstall</code>, and <code>noRebuild</code> are
no longer in use. Their setters are no-ops,their getters returning <code>false</code>.
</p>
</description>
<class package="org.netbeans.modules.gradle.spi.newproject" name="TemplateOperation"/>
</change>
<change id="gradle-wrapper-version">
<api name="general"/>
<summary>Method to set the Gradle version when initalizing the wrapper</summary>
Expand Down
2 changes: 1 addition & 1 deletion extide/gradle/manifest.mf
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ AutoUpdate-Show-In-Client: true
OpenIDE-Module: org.netbeans.modules.gradle/2
OpenIDE-Module-Layer: org/netbeans/modules/gradle/layer.xml
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/gradle/Bundle.properties
OpenIDE-Module-Specification-Version: 2.35
OpenIDE-Module-Specification-Version: 2.36
Original file line number Diff line number Diff line change
Expand Up @@ -1126,7 +1126,6 @@ public static GradleCommandLine getDefaultCommandLine() {

ret.setFlag(Flag.OFFLINE, settings.isOffline());
ret.setFlag(Flag.CONFIGURE_ON_DEMAND, settings.isConfigureOnDemand());
ret.setFlag(Flag.NO_REBUILD, settings.getNoRebuild());
ret.setFlag(Flag.CONFIGURATION_CACHE, settings.getUseConfigCache());

ret.setLogLevel(settings.getDefaultLogLevel());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@

import org.netbeans.modules.gradle.api.NbGradleProject;
import org.netbeans.modules.gradle.api.execute.GradleCommandLine;
import org.netbeans.modules.gradle.spi.GradleSettings;
import java.io.File;
import java.io.IOException;
import java.nio.file.Files;
Expand All @@ -38,9 +37,7 @@
import org.gradle.tooling.GradleConnectionException;
import org.gradle.tooling.GradleConnector;
import org.gradle.tooling.ProjectConnection;
import org.netbeans.modules.gradle.api.execute.GradleDistributionManager;
import org.openide.modules.InstalledFileLocator;
import org.openide.modules.OnStart;
import org.openide.modules.Places;
import org.openide.util.RequestProcessor;

Expand All @@ -67,19 +64,6 @@ public final class GradleDaemon {

private GradleDaemon() {}

@OnStart
public static class Loader implements Runnable {

@Override
public void run() {
GradleSettings settings = GradleSettings.getDefault();
GradleDistributionManager dmgr = GradleDistributionManager.get(settings.getGradleUserHome());
if ( settings.isStartDaemonOnStart() && dmgr.defaultDistribution().isAvailable()) {
GRADLE_LOADER_RP.submit(GradleDaemon::doLoadDaemon);
}
}
}

public static String initScript() {
File initScript = Places.getCacheSubfile("gradle/nb-tooling.gradle"); //NOI18N
synchronized (initScriptReady) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ SettingsPanel.cbSkipCheck.text=Skip 'check' for non-test Related Executions
SettingsPanel.cbSkipTest.text=Skip 'test' for non-test Related Executions
SettingsPanel.cbConfigureOnDemand.text=Configure on Demand
SettingsPanel.cbPreferWrapper.text=Prefer to use Gradle Wrapper that Comes with the Project
SettingsPanel.cbStartDaemonOnStart.text=Start Gradle Daemon on IDE Start
SettingsPanel.lbVersionInfo.text=
SettingsPanel.cbHideEmptyConfig.text=Hide 'Empty' Configurations
SettingsPanel.cbAlwaysShowOutput.text=Always Show Build Output
Expand All @@ -52,13 +51,10 @@ SettingsPanel.lbDownloadSources.text=Download Sources Along with the Dependencie
SettingsPanel.lbDownloadJavadoc.text=Download JavaDoc Along with the Dependencies
SettingsPanel.cbDownloadJavadoc.toolTipText=Not implemented yet.
SettingsPanel.cbDownloadSources.toolTipText=Not implemented yet.
SettingsPanel.cbSilentInstall.text=Install Gradle Runtime Silently
SettingsPanel.btDefaultHome.text=Default
SettingsPanel.lbAllowExecution.text=Allow Gradle Execution:
SettingsPanel.cbBundledLoading.text=Load Projects in Bundles
SettingsPanel.cbBundledLoading.toolTipText=Instead of loading sub-projects of a multi-project build individually, try fetch the sub-project details in one run.
SettingsPanel.cbUseConfigCache.toolTipText=<html>This is an <b>incubating</b> feature. Use with care!
SettingsPanel.cbUseConfigCache.text=Use Configuration Cache
SettingsPanel.cbNoRebuild.text=<html><strike>Do not Rebuild Project Dependencies</strike>
SettingsPanel.cbNoRebuild.toolTipText=<html>This option was removed in Gradle 8.0 as this <b>can lead to wrong results</b>.<br/>\nNetBeans is going to remove it in version 20.<br/>Use with caution!
SettingsPanel.lbNetworkProxy.text=Network Proxy:
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,6 @@ public void update() {
@Override
public void applyChanges() {
getPanel().applyValues();
if (GradleSettings.getDefault().isSilentInstall()) {
// If allowed, let's just install the required Gradle version.
GradleDistributionManager gdm = GradleDistributionManager.get();
GradleDistribution dist = gdm.distributionFromVersion(GradleSettings.getDefault().getGradleVersion());
dist.install();
}
}

@Override
Expand Down
Loading

0 comments on commit 86da2eb

Please sign in to comment.