* CVS-Emacs not reading bash environments?
@ 2007-12-18 19:49 Sven Bretfeld
2007-12-18 22:12 ` Andrea Vettorello
0 siblings, 1 reply; 3+ messages in thread
From: Sven Bretfeld @ 2007-12-18 19:49 UTC (permalink / raw)
To: help-gnu-emacs
[-- Attachment #1.1: Type: text/plain, Size: 914 bytes --]
Hi
I have a strange problem. I'm running Emacs 23.0.50.1 from CVS
(Debian-Snapshot) on a Debian Etch notebook with KDE.
Somehow Emacs doesn't recognize my default CVS repository (CVSROOT)
which is set in ~/.bashrc.
M-x cvs-update aborts with the message:
Repository: ?????
Module:
Working dir: ~/somedir/
No CVSROOT specified! Please use the `-d' option.
The problem occurs when I start Emacs using an icon or the KDE
Startmenue or via Alt-F2. However, it works alright when I start Emacs
directly from the shell ($ emacs RET) or within the shell ($ emacs -nw
RET).
It's also working perfectly on my other two machines which have the
same setup but run an older Emacs snapshot (22.1.50.1).
How is it possible that Emacs doesn't read environments set in .bashrc
when started in the usual way programs are started in X? And how can I
solve the problem?
Thanks for help
Sven
[-- Attachment #1.2: Type: application/pgp-signature, Size: 188 bytes --]
[-- Attachment #2: Type: text/plain, Size: 152 bytes --]
_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: CVS-Emacs not reading bash environments?
2007-12-18 19:49 CVS-Emacs not reading bash environments? Sven Bretfeld
@ 2007-12-18 22:12 ` Andrea Vettorello
0 siblings, 0 replies; 3+ messages in thread
From: Andrea Vettorello @ 2007-12-18 22:12 UTC (permalink / raw)
To: Emacs List
On Dec 18, 2007 8:49 PM, Sven Bretfeld <sven.bretfeld@gmx.ch> wrote:
[...]
> It's also working perfectly on my other two machines which have the
> same setup but run an older Emacs snapshot (22.1.50.1).
>
> How is it possible that Emacs doesn't read environments set in .bashrc
> when started in the usual way programs are started in X? And how can I
> solve the problem?
FWIK, ~/.bashrc is run for (interactive) invocation of bash, you
should put env variables on ~/.profile, or eventually in ~/.xsession
(GDM needs to be explicitly configured to source users xsession files,
don't know about KDM)...
--
Andrea
^ permalink raw reply [flat|nested] 3+ messages in thread
[parent not found: <mailman.5170.1198007379.18990.help-gnu-emacs@gnu.org>]
* Re: CVS-Emacs not reading bash environments?
[not found] <mailman.5170.1198007379.18990.help-gnu-emacs@gnu.org>
@ 2007-12-19 7:39 ` Tim X
0 siblings, 0 replies; 3+ messages in thread
From: Tim X @ 2007-12-19 7:39 UTC (permalink / raw)
To: help-gnu-emacs
Sven Bretfeld <sven.bretfeld@gmx.ch> writes:
> Hi
>
> I have a strange problem. I'm running Emacs 23.0.50.1 from CVS
> (Debian-Snapshot) on a Debian Etch notebook with KDE.
>
> Somehow Emacs doesn't recognize my default CVS repository (CVSROOT)
> which is set in ~/.bashrc.
>
> M-x cvs-update aborts with the message:
>
> Repository: ?????
> Module:
> Working dir: ~/somedir/
>
> No CVSROOT specified! Please use the `-d' option.
>
> The problem occurs when I start Emacs using an icon or the KDE
> Startmenue or via Alt-F2. However, it works alright when I start Emacs
> directly from the shell ($ emacs RET) or within the shell ($ emacs -nw
> RET).
>
> It's also working perfectly on my other two machines which have the
> same setup but run an older Emacs snapshot (22.1.50.1).
>
> How is it possible that Emacs doesn't read environments set in .bashrc
> when started in the usual way programs are started in X? And how can I
> solve the problem?
>
> Thanks for help
>
> Sven
At a guess, I'd say that your X session scripts are not running as login
scripts and therefore are not sourcing your .bash_profile, but KDE is
configured to open shells as a login shell (and hence they do source
.bash_profile).
There are numerous ways to change this -
1. Change your Xsession script to be a login shell
2. Change the command executed when you click on the icon to call a wrapper
script that first sources .bash_profile and then does an exec to emacs
I'm running gdm and normally change the first line of the gdm Xsession
script to be -login so that i know every program I execute via an icon or
menu (I run sawfish, not KDE) will inherit my environment. Some will advise
against this and there probably are good reasons not to do it, but I've
done it this way for nearly 20 years (originally, most Xsession scripts
were setup to be a login shell - not sure why/when this changed). Its
possible there may be security reasons, but as most people running Linux
these days are really running it as a desktop with just a single user, I
don't think you need to worry about some of the so called security concerns
quite as much (compared to a multi-user system with real multiple users).
Tim
--
tcross (at) rapttech dot com dot au
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-12-19 7:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-18 19:49 CVS-Emacs not reading bash environments? Sven Bretfeld
2007-12-18 22:12 ` Andrea Vettorello
[not found] <mailman.5170.1198007379.18990.help-gnu-emacs@gnu.org>
2007-12-19 7:39 ` Tim X
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.