更新时间:2022-06-11 01:58:12
我使用 IntelliJ IDEA 2017.1遇到了同样的问题。 5
但我能够使用 Maven
。我创建了一个 GitHub
存储库,其中包含更新的插件源代码这里。
I had the same problem using IntelliJ IDEA 2017.1.5
but I was able to get it working with Maven
. I created a GitHub
repository with the updated plugin source code here.
首先,克隆项目。
在 ideauidesigner-maven-plugin-master
文件夹,运行 install-intellij-libs.sh
脚本来安装 IntelliJ
库到您当地的maven存储库中:
In the ideauidesigner-maven-plugin-master
folder, run the install-intellij-libs.sh
script to install the IntelliJ
libraries into your local maven repository:
./install-intellij-libs.sh <path to your IntelliJ directory>
这里也是一个批处理文件( install-intellij-libs.bat
)对于Windows:
Here is also a batch file (install-intellij-libs.bat
) for Windows:
SET INTELLIJ_HOME=C:\Program Files\JetBrains\IntelliJ IDEA 173.3188.16 REM Edit this to match your path!
CALL mvn install:install-file -Dfile="%INTELLIJ_HOME%\lib\javac2.jar" -DgroupId=com.intellij -DartifactId=javac2 -Dversion=17.1.5 -Dpackaging=jar
CALL mvn install:install-file -Dfile="%INTELLIJ_HOME%\lib\asm-all.jar" -DgroupId=com.intellij -DartifactId=asm-all -Dversion=17.1.5 -Dpackaging=jar
CALL mvn install:install-file -Dfile="%INTELLIJ_HOME%\lib\forms_rt.jar" -DgroupId=com.intellij -DartifactId=forms_rt -Dversion=17.1.5 -Dpackaging=jar
然后通过运行以下命令安装新插件:
Then install your new plugin by running the following:
mvn install
现在你已经完成了设置环境的工作。
Now you're done with setting up your environment.
在您的实际项目中,将 pom.xml
中的插件版本编辑为:
In your actual project, edit the plugin's version in your pom.xml
to this:
<version>1.0-beta-2-17.1.5</version>
还添加以下依赖项:
<dependency>
<groupId>com.intellij</groupId>
<artifactId>javac2</artifactId>
<version>LATEST</version>
</dependency>
<dependency>
<groupId>com.intellij</groupId>
<artifactId>forms_rt</artifactId>
<version>LATEST</version>
</dependency>
<dependency>
<groupId>com.intellij</groupId>
<artifactId>asm-all</artifactId>
<version>LATEST</version>
</dependency>
现在构建应该可以正常使用UI设计器表单。
Now building should work correctly with UI designer forms.