Intellij IDEA--解决“Command line is too long”

ゝ一纸荒年。 2023-09-30 10:49 122阅读 0赞

原文网址:Intellij IDEA—解决“Command line is too long”_IT利刃出鞘的博客-CSDN博客

简介

本文介绍如何解决IDEA启动项目时的报错:Command line is too long

错误日志

Error running ‘ServiceStarter’: Command line is too long. Shorten command line for ServiceStarter or also for Application default configuration.

解决方法1

Run=> Edit Configuration=> SpringBoot=> Configuration=> Environment=> Shorten command line=>
将none项改为”Jar manifest”

解决方法2

修改项目下 .idea\workspace.xml,找到标签 , 在标签里加一行

  1. <property name="dynamic.classpath" value="true" />

解释

该选项控制如何将classpath传递给JVM:通过命令行或通过文件。大多数操作系统都有最大的命令行限制,当它超过时,IDEA将无法运行您的应用程序。 当命令行长于32768个字符时,IDEA建议您切换到动态类路径,长类路径被写入文件,然后由应用程序启动器读取并通过系统类加载器加载。

发表评论

表情:
评论列表 (有 0 条评论,122人围观)

还没有评论,来说两句吧...

相关阅读