LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   xfce launcher & inherit env (https://www.linuxquestions.org/questions/slackware-14/xfce-launcher-and-inherit-env-771401/)

cmk77 11-25-2009 02:50 AM

xfce launcher & inherit env
 
In the xfce panel I made a launcher button for emacs but I find that the bashrc environment is not inherited. So now I have to open a terminal and type emacs which is a bit of a nuisance. Is there any way to tell the launcher to inherit my environment?

timmeke 11-25-2009 04:36 AM

Is there not a checkbox for "run in terminal"?

cmk77 11-25-2009 05:21 AM

yes, there is. But if I check the box "run in terminal" it just opens xterm and doesn't launch emacs.

timmeke 11-25-2009 07:11 AM

Sounds strange. Anyway, perhaps you can write a simple script to start emacs in proper environment and use the Launcher to run that script?

catkin 11-25-2009 10:58 AM

Here's a command line used in an Xfce launcher to start an mrxvt terminal, run a command in it and leave the terminal open. Perhaps it can be adapted to run emacs in the terminal emulator you are using. The bash --rcfile technique was one of the first golden nuggets I learned from LQ.
Code:

/usr/bin/mrxvt -e /bin/bash --rcfile /home/c/d/bin/.MyConnectivityTestWrapper.rc
MyConnectivityTestWrapper.rc simply sources ~/.bashrc and then runs the desired (connectivity test) command.

cmk77 11-26-2009 02:19 AM

Thanks! I changed it to:
Code:

/bin/bash --rcfile /path/to/bashrc -c /usr/bin/emacs


All times are GMT -5. The time now is 06:32 AM.