小编Guy*_*rom的帖子

具有 .bashrc 环境的 .desktop 文件

我使用的是 IntelliJ IDEA,它使用了 .bashrc 脚本中定义的一些环境变量。

如果我从终端运行它的 shell 脚本一切正常,但是如果我创建一个 .desktop 文件来从启动器运行它,那么它会在没有 .bashrc 环境的情况下加载。

我还尝试使用“使用终端运行”选项,但没有帮助。有没有办法做这些事情?

桌面文件的内容:

[Desktop Entry]
Version=1.0
Type=Application
Name=IntelliJ IDEA
Icon=/home/gmarom/bin/idea-IU-135.1230/bin/idea.png
Exec="/home/gmarom/bin/idea-IU-135.1230/bin/idea.sh" %f
Comment=Develop with pleasure!
Categories=Development;IDE;
Terminal=false
StartupWMClass=jetbrains-idea
Run Code Online (Sandbox Code Playgroud)

launcher bashrc .desktop

9
推荐指数
2
解决办法
5822
查看次数

标签 统计

.desktop ×1

bashrc ×1

launcher ×1