eclipse为所有项目设置了全球环境 [英] eclipse set global environment for all projects

查看:81
本文介绍了eclipse为所有项目设置了全球环境的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于每个项目,我可以设置环境,当我选择运行它。可以设置运行时所有项目将继承的全局环境吗?

for each project, i able to set environment when i select "run it as" . can i set global environment that all project will inherit when run?

推荐答案

您可以在启动Eclipse的脚本中设置环境变量。

You can set environment variables in a script that starts Eclipse. These should be inherited by all child processes.

创建一个包含以下内容的小脚本:

Create a small script which contains this:

export JAVA_HOME=....
....path-to-eclipse.../eclipse.exe

不知道Mac上的.exe。将eclipse可执行文件的绝对路径放在 export 下面的行中,它应该可以工作。要使脚本可执行,请使用 chmod + x scriptname

Not sure about the ".exe" on Mac. Just put the absolute path of the eclipse executable in the line below the export and it should work. To make the script executable, use chmod +x scriptname

这篇关于eclipse为所有项目设置了全球环境的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆