Skip to content

Commit

Permalink
Revert package rename (#26)
Browse files Browse the repository at this point in the history
* Revert "build: use pluginVerifier for quality assurance (#22)"

This reverts commit 0db0731.

* Revert "chore: adjust file tree to package names"

This reverts commit 5e131d9.
  • Loading branch information
tim-sh authored Apr 16, 2024
1 parent 5e131d9 commit c7dfe0e
Show file tree
Hide file tree
Showing 15 changed files with 44 additions and 48 deletions.
2 changes: 1 addition & 1 deletion .github/actions/gradle-run/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ runs:
if: ${{ contains(inputs.steps, 'build') }}
shell: bash
run: |
./gradlew runPluginVerifier buildPlugin
./gradlew buildPlugin
ls -la build/distributions
- name: Test
Expand Down
4 changes: 0 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,6 @@ tasks {
dependsOn 'copyLsp'
}

verifyPlugin {
dependsOn 'copyLsp'
}

test {
dependsOn 'copyLspToInstrumented'
}
Expand Down
13 changes: 0 additions & 13 deletions src/main/java/com/sap/cap/cds/Plugin.java

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds;
package com.sap.cap.cds.intellij;

import com.intellij.openapi.fileTypes.LanguageFileType;
import com.intellij.openapi.util.NlsContexts;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds;
package com.sap.cap.cds.intellij;

import com.intellij.openapi.util.IconLoader;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds;
package com.sap.cap.cds.intellij;

public class Language extends com.intellij.lang.Language {

Expand Down
13 changes: 13 additions & 0 deletions src/main/java/com/sap/cap/cds/intellij/Plugin.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package com.sap.cap.cds.intellij;

public class Plugin {

/* Overview of all relevant IDs, names, and labels for the plugin itself */

public static final String ID = "com.sap.cap.cds.intellij"; // Should not be changed. See plugin.xml

public static final String PACKAGE = "com.sap.cap.cds.intellij";

public static final String LABEL = "intellij-cds"; // Used for build subfolder and zip file

}
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.sap.cap.cds.lsp;
package com.sap.cap.cds.intellij.lsp;

import com.intellij.execution.ExecutionException;
import com.intellij.execution.configurations.GeneralCommandLine;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.platform.lsp.api.ProjectWideLspServerDescriptor;
import com.intellij.platform.lsp.api.customization.LspFormattingSupport;
import com.sap.cap.cds.FileType;
import com.sap.cap.cds.intellij.FileType;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.sap.cap.cds.lsp;
package com.sap.cap.cds.intellij.lsp;

import com.intellij.openapi.project.Project;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.platform.lsp.api.LspServer;
import com.intellij.platform.lsp.api.lsWidget.LspServerWidgetItem;
import com.sap.cap.cds.FileType;
import com.sap.cap.cds.Icons;
import com.sap.cap.cds.Language;
import com.sap.cap.cds.textmate.BundleManager;
import com.sap.cap.cds.intellij.FileType;
import com.sap.cap.cds.intellij.Icons;
import com.sap.cap.cds.intellij.Language;
import com.sap.cap.cds.intellij.textmate.BundleManager;
import kotlin.jvm.internal.Intrinsics;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds.textmate;
package com.sap.cap.cds.intellij.textmate;

public class Bundle {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds.textmate;
package com.sap.cap.cds.intellij.textmate;


import com.intellij.ide.AppLifecycleListener;
Expand All @@ -8,9 +8,9 @@
import com.intellij.openapi.startup.ProjectActivity;
import com.intellij.openapi.startup.StartupActivity;
import com.intellij.util.PathUtil;
import com.sap.cap.cds.Language;
import com.sap.cap.cds.util.Logger;
import com.sap.cap.cds.Plugin;
import com.sap.cap.cds.intellij.Language;
import com.sap.cap.cds.intellij.util.Logger;
import com.sap.cap.cds.intellij.Plugin;
import kotlin.Unit;
import kotlin.coroutines.Continuation;
import org.jetbrains.annotations.NotNull;
Expand All @@ -22,8 +22,8 @@
import java.nio.file.Paths;
import java.util.List;

import static com.sap.cap.cds.util.StackUtil.getCaller;
import static com.sap.cap.cds.util.StackUtil.getMethod;
import static com.sap.cap.cds.intellij.util.StackUtil.getCaller;
import static com.sap.cap.cds.intellij.util.StackUtil.getMethod;

public class BundleManager implements AppLifecycleListener, /*obsolete*/ StartupActivity, /* replacement*/ ProjectActivity, DynamicPluginListener {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.sap.cap.cds.util;
package com.sap.cap.cds.intellij.util;

import com.sap.cap.cds.Plugin;
import com.sap.cap.cds.textmate.Bundle;
import com.sap.cap.cds.intellij.Plugin;
import com.sap.cap.cds.intellij.textmate.Bundle;

import static com.intellij.openapi.diagnostic.Logger.*;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sap.cap.cds.util;
package com.sap.cap.cds.intellij.util;

public class StackUtil {
public static StackTraceElement getCaller(int depth) {
Expand Down
14 changes: 7 additions & 7 deletions src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<idea-plugin>
<id>com.sap.cap.cds</id>
<id>com.sap.cap.cds.intellij</id>
<name>CAP CDS Language Support</name>
<category>Custom Language</category>
<vendor url="https://sap.com">SAP SE</vendor>
Expand Down Expand Up @@ -27,34 +27,34 @@ The set of features will grow with future releases of the plugin, according to t
<extensions defaultExtensionNs="com.intellij">
<fileType
name="cds"
implementationClass="com.sap.cap.cds.FileType"
implementationClass="com.sap.cap.cds.intellij.FileType"
fieldName="INSTANCE"
language="cds"
extensions="cds"/>
<platform.lsp.serverSupportProvider implementation="com.sap.cap.cds.lsp.ServerSupportProvider"/>
<platform.lsp.serverSupportProvider implementation="com.sap.cap.cds.intellij.lsp.ServerSupportProvider"/>
</extensions>

<applicationListeners>
<listener
topic="com.intellij.ide.AppLifecycleListener"
class="com.sap.cap.cds.textmate.BundleManager"
class="com.sap.cap.cds.intellij.textmate.BundleManager"
activeInHeadlessMode="true" activeInTestMode="true"
/>
<listener
topic="com.intellij.openapi.startup.StartupActivity"
class="com.sap.cap.cds.textmate.BundleManager"
class="com.sap.cap.cds.intellij.textmate.BundleManager"
activeInHeadlessMode="true" activeInTestMode="true"
/>
<listener
topic="com.intellij.ide.plugins.DynamicPluginListener"
class="com.sap.cap.cds.textmate.BundleManager"
class="com.sap.cap.cds.intellij.textmate.BundleManager"
activeInHeadlessMode="true" activeInTestMode="true"
/>
</applicationListeners>
<projectListeners>
<listener
topic="com.intellij.openapi.startup.ProjectActivity"
class="com.sap.cap.cds.textmate.BundleManager"
class="com.sap.cap.cds.intellij.textmate.BundleManager"
activeInHeadlessMode="true" activeInTestMode="true"
/>
</projectListeners>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package com.sap.cap.cds;
package com.sap.cap.cds.intellij;

import com.intellij.execution.ExecutionException;
import com.intellij.execution.configurations.GeneralCommandLine;
import com.intellij.testFramework.fixtures.BasePlatformTestCase;
import com.intellij.testFramework.fixtures.TempDirTestFixture;
import com.sap.cap.cds.lsp.ServerDescriptor;
import com.sap.cap.cds.intellij.lsp.ServerDescriptor;

import java.io.*;
import java.util.regex.Pattern;
Expand Down

0 comments on commit c7dfe0e

Please sign in to comment.