我有一个脚本,它需要调用现有的无头 Eclipse 应用程序之一(例如:p2 director 应用程序),它使用Proxy APIorg.eclipse.core.net
来配置其对 HTTP 服务器的请求。
在 Linux 上,我可以通过设置环境变量http_proxy
和https_proxy
.
是否有类似的解决方案可以从 Windows 中的命令行配置代理?
我尝试设置由 Java( 、 等)指定的 HTTP 代理配置属性http.proxyHost
,http.proxyPort
但这不起作用。设置属性只会导致来自 Eclipse 的日志条目通知我系统属性已被首选项中的值覆盖:
!ENTRY org.eclipse.core.net 1 0 2013-08-09 15:21:19.413
!MESSAGE System property http.proxyHost has been set to proxy by an external source. This value will be overwritten using the values from the preferences
!ENTRY org.eclipse.core.net 1 0 2013-08-09 15:21:19.414
!MESSAGE System property http.proxyPort has been set to 8080 by an external source. This value will be overwritten using the values from the preferences
因此,另一种选择是允许配置首选项的无头应用程序。该应用程序是否存在(最好作为标准 Eclipse 发行版的一部分)?