用于查找可安装单元的p2 director命令行参数不返回信息

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了用于查找可安装单元的p2 director命令行参数不返回信息相关的知识,希望对你有一定的参考价值。

我试图使用p2 director和命令行参数从p2存储库中获取可安装单元的列表。我从这篇文章的步骤开始使用-list参数:

Command line to find units in a p2 repository using p2 query language

但是,当我运行p2 director时,命令行什么都不返回。

我的命令行如下所示:

"C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipse"eclipsec.exe -application org.eclipse.equinox.p2.director -debug "C:UsersIBM_ADMINDocumentsprojectslocaltpbuildp2Options.txt" -repository 

如您所见,我使用-debug命令打开调试。我的选项文件包含:

org.eclipse.equinox.p2.core/debug=true
org.eclipse.equinox.p2.core/artifacts/mirrors=true

我正在从批处理文件中运行命令:

@ECHO OFF
SET _EXEDIR_="C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipse"
SET _REPO_=https://download.eclipse.org/technology/swtbot/releases/latest/
@ECHO Querying P2...
@ECHO ON
%_EXEDIR_%eclipsec.exe -application org.eclipse.equinox.p2.director -debug "C:UsersIBM_ADMINDocumentsprojectslocaltpbuildp2Options.txt" -repository %_REPO_% -list
@ECHO P2 query complete.
@ECHO OFF
pause

结果显示调试信息,但没有条目,是:

Querying P2...

C:UsersIBM_ADMINDocumentsprojectslocaltpbuild>"C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipse"eclipsec.exe -application org.eclipse.equinox.p2.director -debug "C:UsersIBM_ADMINDocumentsprojectslocaltpbuildp2Options.txt" -repository https://download.eclipse.org/technology/swtbot/releases/latest/ -list
Start VM: C:/IBM/IBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5/eclipseDevelopmentPackage/ibm_sdk80/jre/bin/javaw.exe
-Xms256m
-Xmx1024m
-XX:MaxPermSize=256m
-XX:PermSize=64m
-Dosgi.requiredJavaVersion=1.6
-Dosgi.bundlefile.limit=100
-Dhttps.protocols=TLSv1.2,TLSv1.1,TLSv1
-jar C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipsepluginsorg.eclipse.equinox.launcher_1.4.0.v20161219-1356.jar
-os win32
-ws win32
-arch x86
-showsplash
-launcher C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipseeclipsec.exe
-name IBM Development Package for Eclipse
--launcher.library C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipsepluginsorg.eclipse.equinox.launcher.win32.win32.x86_1.1.500.v20170531-1133eclipse_1624.dll
-startup C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipsepluginsorg.eclipse.equinox.launcher_1.4.0.v20161219-1356.jar
--launcher.overrideVmargs
-exitdata 3db8_a0
-application org.eclipse.equinox.p2.director
-debug C:UsersIBM_ADMINDocumentsprojectslocaltpbuildp2Options.txt
-repository https://download.eclipse.org/technology/swtbot/releases/latest/
-list
-vm C:/IBM/IBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5/eclipseDevelopmentPackage/ibm_sdk80/jre/bin/javaw.exe
-vmargs
-Xms256m
-Xmx1024m
-XX:MaxPermSize=256m
-XX:PermSize=64m
-Dosgi.requiredJavaVersion=1.6
-Dosgi.bundlefile.limit=100
-Dhttps.protocols=TLSv1.2,TLSv1.1,TLSv1
-jar C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageeclipsepluginsorg.eclipse.equinox.launcher_1.4.0.v20161219-1356.jar

P2 query complete.
Press any key to continue . . .

我错过了什么吗?

答案

看来你遇到了Eclipse bug 417799

解决方法是将以下内容添加到命令行(使用...serverjvm.dll而不是...javaw.exe):

-vm C:IBMIBM_DevelopmentPackage_for_Eclipse_Win_X86_32_6.5.5eclipseDevelopmentPackageibm_sdk80jreinserverjvm.dll

以上是关于用于查找可安装单元的p2 director命令行参数不返回信息的主要内容,如果未能解决你的问题,请参考以下文章

P2p 寻找其他客户端(用于分布式计算项目)

Vim命令之查找和替换

如何将 exec 参数中的管道用于查找命令?

gtest命令行测试案例

用于查找单元格值是不是在范围内的双 For 循环

whereiswhichfind的区别