ACPI administration advocacy advocacy advocacy opinion alsa amarok apache apple apt aptitude audio audo authentication automount avi awk bash BIOS boot business cache calendar calibre cdr cdrecord censorship commandline computerscience console convert cron cut database date debian degree design desktop development disk dpkg dvd economics education emacs email europe exim faad ffmpeg file files firefox firewall flash foss freedom ftp fun fuse git gnumeric graphics grep growisofs grub gtkpod hardware hardware html idiocy image imagemagick images installation ip iphone ipod iptables iso itunes ivman kde kernel keyboard knoppix lame laptop latex linux locale lockin longlines m4a microsoft mimetypes minitab mount mp3 mp4 mplayer multimedia music mysql network nfs nfs4 nmap openbox openoffice opinion opinion partition pdf perl php politics postgresql printing privacy programming rant remote rhythmbox rss rsync rxvt scp screengrab screenshot script scripting scsi security sed server shell siteadmin sitenews sitesoftware skype skype slackware sound sox spam spreadsheet ssh statistics subversion sudo svk swap t23 t43 terminal text thinkpad thunderbird time timezone ubuntu udev upgrade usb usbmount users uuid versioncontrol vfat video vnc windows wine wordpress wordprocessing X40 xwindows xwindows youtube
There is little as annoying as your computer not running as you think it should. This very thing has been happening to me in the last few days.
One thing that I really like is typesetting documents in TeX and LaTeX. These typesetting languages are like many things in GNU/Linux, in that once you start doing anything serious you need to have your own libraries.
TeX has the path to its libraries in an environment variable TEXINPUTS. So, you can set TEXINPUTS like you can with other environment variables:
export TEXINPUTS=$TEXINPUTS:$HOME/mylibs::
That's what I thought. That's what I did. Did it work? Did it hell. Emacs, whose TeX mode is great, just wasn't finding my libraries. I tried setting TEXINPUTS in .bashrc, .bash_profile, .profile, but nothing worked.
But then it did. A bit. When I ssh'ed to the computer using X forwarding, emacs correctly found TEXINPUTS. Something odd was going on here.
If it was running OK in an SSH session, would it also run properly if started emacs from a xterm? So, I tested it by starting emacs from a console window instead of from the K Menu. It worked correctly. Suddenly, it dawned on me; it was a KDE problem. KDE just wasn't running .bashrc, or .bash_profile or .profile or anything else.
I hit Google to come up with an answer. Yes, it is known. Even though, I'd call it a bug, apparently it isn't, it's a 'feature' which isn't going away. So, we need a permanent work-around.
The answer is to be found here: http://lists.debian.org/debian-kde/2005/05/msg00079.html.
The best solution is to create a file, for example /etc/X11/Xsession.d/85LOCAL-sourcefiles that runs for every user when they start an X session. The file should contain this:
if test -f $HOME/.Xsession-common; then
. $HOME/.Xsession-common
fi
This way, you can set your environment variables in ~/.Xsession-common. At the moment though I'm setting the environment variable in ~/.xsession just before I call 'startkde'.
So, there you have it - my sanity was saved.