ChaniBlog











{September 30, 2008}   sneaky little scripts

so I was getting rather frustrated the past couple of weeks, because vars I’d set didn’t seem to be sticking, no matter where I called my scripts from. I got *really* frustrated yesterday when I realised that I was also still running packages for kdebase stuff, not the code I’d compiled myself. *after* making three commits to this code. doh.

last night I finally figured it out: there were some “helpful” little scripts lurking on my system, changing things after my scripts set them and setting other things that confused kde4. a script in /usr/env/ was setting up its own ssh and gpg agents, overriding mine (I like to keep them running between kde sessions, especially when debugging). then /etc/profile.d/kde3.sh was setting KDEDIRS, which confused kde4 into ignoring my stuff and always running packages instead.

so, I’ve disabled those scripts and I can finally run compiled code. :) yay! the stuff I committed before fixing this was just the stuff I wrote at akademy and never finished; after that I committed some minor little cleanups.

…it’s not all perfect, though. ssh-agent works, but kmail still believes gpg-agent got a bad passphrase without ever asking me for one at all. I’m still running kdemod packages for everything other than kdebase and plasmoids… kmail completely ignores kwallet, akregator says it has some problem with metakit and won’t archive my feeds, and kmix won’t bring up the mixer window. guess I’ll have to compile them myself so that everything’s on the same revision.

then there’s some regression in powerdevil: when using packages, powerdevil worked perfectly but kickoff’s suspend/hibernate buttons did nothing. now that I’m running yesterday’s trunk, powerdevil also does nothing. since hibernating is pretty important at school, I might have to go back to packages temporarily until I figure out what changed. oh, and disabling the kde3.sh entirely means that kde can’t see basKet (my one non-kde4 program) any more, so I’ll have to go back and fix that one properly.

[update: I fixed my KDEDIRS properly and untangled exactly what was being called when. I now have akregator and kmix and basket happy. kmail and gpg-agent haven’t changed (the kwalllet thing probably does require an update, iirc). surprisingly, powerdevil works again, although it forgot some of my settings, and kickoff’s suspend buttons work too!]

still, I’m happy to be writing code again. :) whee!
…except now it’s time to study for tomorrow’s midterms instead.
if anyone is interested in taking one of my tasks from the feature plan, feel free. (I think someone in #plasma was interested in dbus interfaces..?) I’m going to have my hands full debugging my soc project’s bitrot and keeping up with school. :/



sandsmark says:

for gpg-agent to work with kmail, you should put a file in for example “~/.kde4/env/”, named something like “gpg-agent.sh”, with the following content:
#!/bin/bash
eval “$(gpg-agent –daemon)”

I have no idea what is causing the rest of your troubles =/
Are you using 64bit or 32bit?



Chani says:

yes, I have that script (with some modifications). or rather, I had both my own and one in /usr/env/ and mine was getting clobbered by the second one, but even with that fixed it never asks me for a passphrase.

and it’s 32-bit.



Chani says:

on the gpg-agent thing… while I was fixing scripts I switched its config to try pinentry-gtk (I’ve had trouble with -qt in hte past) but even that didn’t help. I’m not sure if it’s kmail or gpg-agent to blame. fwiw, I never managed to get it working on gentoo years and years ago, but it worked easily on kubuntu. it could be that kubuntu does something extra that I’ve missed.



KMail can’t find GPGAgent. That probably means the environment variable is still getting screwed.

Environment variables suck. Currently, Amarok works fine for me if I run it from the console. But moving to the next track and playing tracks with non-ascii characters in the filename are both broken when I run it from Kickoff.



Comments are closed.

et cetera
%d bloggers like this: