LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-20-2008, 07:41 AM   #1
ChrisAbela
Member
 
Registered: Mar 2008
Location: Malta
Distribution: Slackware and Debian
Posts: 514

Rep: Reputation: 108Reputation: 108
Fluxbox environment variables


I am running Fluxbox on my brand new Slack 12.1 and when I run any terminal I noticed that I am not inheriting the environment variables laid out in /etc/profile. I had the same problem on Xfce and KDE but I cannot sort it out on Fluxbox. Should anyone be running on Fluxbox, I would appreciate any hints.

Chris
 
Old 05-20-2008, 08:52 AM   #2
indienick
Senior Member
 
Registered: Dec 2005
Location: London, ON, Canada
Distribution: Arch, Ubuntu, Slackware, OpenBSD, FreeBSD
Posts: 1,853

Rep: Reputation: 65
I ran into the same problem with WindowMaker - unfortunately, I couldn't find a fix for it. Constantly having to "source /etc/profile && source ~/.bashrc" was a pain in the butt.
 
Old 05-20-2008, 11:39 AM   #3
vadkutya
Member
 
Registered: Apr 2008
Distribution: slackware 10.2
Posts: 117

Rep: Reputation: 16
do you have a .profile in your home dir? if so alter it according to your likings. if not try to create it and see how it goes. what exactly is the problem?

vadkutya
 
Old 05-21-2008, 11:05 AM   #4
ChrisAbela
Member
 
Registered: Mar 2008
Location: Malta
Distribution: Slackware and Debian
Posts: 514

Original Poster
Rep: Reputation: 108Reputation: 108
Thank you for the suggestion, but it does not work.
I am running runlevel 3 and the environment variables would be correct as long as I stay in TTY1-6, then I run Fluxbox via startx and I start a Terminal. At this point the variables are not inhereted. I am suspecting that I need to set up Fluxbox properly.

Running directly in runlevel 4 did not help.
 
Old 05-22-2008, 09:41 AM   #5
ChrisAbela
Member
 
Registered: Mar 2008
Location: Malta
Distribution: Slackware and Debian
Posts: 514

Original Poster
Rep: Reputation: 108Reputation: 108
For the sake of others who have (or shall) encounter the same problem I would like to post a temporary solution to this issue:

$cd
enter the following line in bold in .fluxbox/menu
....
[encoding] {UTF-8}
[exec] (Terminal) {terminal}
[exec] (rxvt) {rxvt}
.......
Open the new Terminal from the Fluxbox menu and then apply the usual Terminal settings:

Right Click>>Terminal
On the Terminal
Edit>>Preferences>>General
Tick Run command in login shell.

Last edited by ChrisAbela; 05-22-2008 at 12:20 PM.
 
Old 05-22-2008, 01:18 PM   #6
Hangdog42
LQ Veteran
 
Registered: Feb 2003
Location: Maryland
Distribution: Slackware
Posts: 7,803
Blog Entries: 1

Rep: Reputation: 416Reputation: 416Reputation: 416Reputation: 416Reputation: 416
I hope I don't get this one backwards.....

Slackware uses two files to customize your consoles:

~/.bash_profile - this is run when you log into the system
~/.bashrc - this is run when you open a new terminal (and being in fluxbox shouldn't affect this)

I've modified my environment variables in both, and I use fluxbox all the time.

In Slackware, modifying /etc/profile is kind of frowned upon simply because there is no guarantee that it will survive the next upgrade.
 
Old 05-23-2008, 08:10 AM   #7
ChrisAbela
Member
 
Registered: Mar 2008
Location: Malta
Distribution: Slackware and Debian
Posts: 514

Original Poster
Rep: Reputation: 108Reputation: 108
Yes you got it right.
Thanks for the help, ~/.bash_rc is the relevant file.
In my case I just sourced /etc/profile:
. /etc/profile
This keeps resetting my wallpaper but I will sort that out when I have time.
My compliments for your website.
It seems that there is a lot to learn about Fluxbox, so now I am hooked.

Have Fun!
 
  


Reply

Tags
slackware


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Environment variables rumi2 Linux - Newbie 2 01-17-2007 07:44 PM
Getting all environment variables Harlin Linux - General 2 10-06-2006 01:30 PM
Environment variables kdnt Linux - Newbie 11 11-01-2002 09:19 AM
environment variables. jISV Linux - General 0 04-05-2002 07:01 AM
environment variables aethereal Linux - Newbie 7 12-19-2001 10:34 AM


All times are GMT -5. The time now is 01:17 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration