From 0f4aa1a33705c028f2f7cdc638af172412470b26 Mon Sep 17 00:00:00 2001 From: duanledexianxianxian Date: Mon, 14 Oct 2019 18:03:40 +0800 Subject: [PATCH] add doc --- plugin-gradle/build.gradle | 27 ------------------- .../plugin/idea/action/HelloAction.java | 20 ++++++++++++++ .../src/main/resources/META-INF/plugin.xml | 13 +++++---- 3 files changed, 28 insertions(+), 32 deletions(-) delete mode 100644 plugin-gradle/build.gradle create mode 100644 plugin-gradle/src/main/java/com/duanledexianxianxian/plugin/idea/action/HelloAction.java diff --git a/plugin-gradle/build.gradle b/plugin-gradle/build.gradle deleted file mode 100644 index 4921506..0000000 --- a/plugin-gradle/build.gradle +++ /dev/null @@ -1,27 +0,0 @@ -plugins { - id 'java' - id 'org.jetbrains.intellij' version '0.4.10' -} - -group 'com.duanledexianxianxian' -version '1.0-SNAPSHOT' - -sourceCompatibility = 1.8 - -repositories { - mavenCentral() -} - -dependencies { - testCompile group: 'junit', name: 'junit', version: '4.12' -} - -// See https://github.com/JetBrains/gradle-intellij-plugin/ -intellij { - version '2019.1' -} -patchPluginXml { - changeNotes """ - Add change notes here.
- most HTML tags may be used""" -} \ No newline at end of file diff --git a/plugin-gradle/src/main/java/com/duanledexianxianxian/plugin/idea/action/HelloAction.java b/plugin-gradle/src/main/java/com/duanledexianxianxian/plugin/idea/action/HelloAction.java new file mode 100644 index 0000000..d968b65 --- /dev/null +++ b/plugin-gradle/src/main/java/com/duanledexianxianxian/plugin/idea/action/HelloAction.java @@ -0,0 +1,20 @@ +package com.duanledexianxianxian.plugin.idea.action; + +import com.intellij.openapi.actionSystem.AnAction; +import com.intellij.openapi.actionSystem.AnActionEvent; +import com.intellij.openapi.project.Project; +import com.intellij.openapi.ui.Messages; + +/** + * @author Administrator + */ +public class HelloAction extends AnAction { + public HelloAction() { + super("Hello"); + } + + public void actionPerformed(AnActionEvent event) { + Project project = event.getProject(); + Messages.showMessageDialog(project, "Hello world!", "Greeting", Messages.getInformationIcon()); + } +} diff --git a/plugin-gradle/src/main/resources/META-INF/plugin.xml b/plugin-gradle/src/main/resources/META-INF/plugin.xml index 8e6f3ac..cb919fe 100644 --- a/plugin-gradle/src/main/resources/META-INF/plugin.xml +++ b/plugin-gradle/src/main/resources/META-INF/plugin.xml @@ -1,11 +1,10 @@ com.duanledexianxianxian.plugin-gradle - Plugin display name here - YourCompany + example + duanledexianxianxian - most HTML tags may be used + Create idea plguin by gradle Just fot test ]]> + + + + - \ No newline at end of file + -- GitLab