[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: debian sensible browser help



On Wed, Jul 27, 2011 at 06:12:10PM -0600, Bob Proulx wrote:
> Robert Holtzman wrote:
> > Bob Proulx wrote:
> > > It definitely is not on mine.  Not on Lenny, Squeeze, nor Sid.  I just
> > > double checked by doing the tests.  Variable settings in .bashrc are
> > > not available to GNOME.
> > 
> > I have this in my .bashrc and they work with no problem:
> > 
> > NNTPSERVER='news.sonic.net' && export NNTPSERVER
> > BROWSER=firefox/firefox && export BROWSER
> 
> If you are launching something from a shell command line then they
> would have those settings.  But unless something is configured as
> other than default I don't know how they would appear in the X and
> GNOME environment.  But very likely you already fixed it long ago. :-)

A long time ago I learned something: no matter how much you know about
linux, every once in a while it rears back and slaps you upside the head
to remind you that you still have a looooooong way to go. I just got
reminded again. I deleted the FF line from .bashrc. Works fine because
FF is the default in Preferences. What was throwing me was that the NNTP
server line *was* required. Then it dawned on me that I was calling my
news reader (slrn) from the command line. Your sentence quoted above is
the key.

> 
> Here is the way I looked for environment variables that GNOME knows
> about.  I created this following simple script.
> 
> #!/bin/sh
> exec >/var/tmp/env.trace.out 2>&1
> echo "============ hello"
> env
> echo "============ goodbye"
> exit 0
> 
> I put that in my ~/bin/env.dumper file and chmod a+x on it.  Then I
> right clicked on the GNOME menu bar and clicked "Add to panel..." then
> selected "Custom Application Launcher" and then "+Add" and then filled
> the path to the script in for the command field.
> 
> With that in place I could test the different environments.  Running
> it from the command line would of course show all of my shell
> variables including those that were set from the .bashrc file.  But
> running it from GNOME itself through the launcher would not.
> 
> Creating the test script seems a little less crass than adding similar
> env dump modifications to /usr/bin/sensible-browser itself.  But doing
> so there would of course eliminate the extraneous script.  I would
> move it out of the way and copy it back and then edit the copy.  Then
> after all of the debug was done I could simply move the original back
> into place and it would completely clean up my debug hacking.

That's great. I have to try that when I have time to do some
experimenting.

> 
> > > So let's say you have GNOME preferences configured so that the web
> > > browser will be sensible-browser.  In that case it won't get the
> > > BROWSER variable setting in .bashrc and then won't launch the desired
> > > browser.
> > 
> > If that's true (and I'm not saying it isn't) how to explain the browser
> > and nntp lines in my .bashrc working. I still have a hunch I'm
> > misunderstanding something.
> 
> I am sure it would all make sense if we knew everything that was
> happening.
> 
> > > > > Instead for GNOME
> > > > > it appears in /etc/X11/Xsession.d/55gnome-session_gnomerc that you
> > > > > need to put settings into ~/.gnomerc instead.  I mention this because
> > > > > Paul said he was running GNOME.  Users running other session managers
> > > > > would be better served to use ~/.xsession.
> > 
> > Haven't set up either one of these. Probably won't as long as the
> > .bashrc is working.
> 
> I tend to agree that if it isn't broken then don't fix it.  But
> knowing what is really going on would be comforting.  And would
> probably help in the future when it does break.
 
I think you nailed it pretty good. 


-- 
Bob Holtzman
If you think you're getting free lunch, 
check the price of the beer.
Key ID: 8D549279

Attachment: signature.asc
Description: Digital signature


Reply to: