LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices


Reply
  Search this Thread
Old 04-11-2005, 04:40 AM   #1
rohr
Member
 
Registered: Jan 2005
Distribution: debian
Posts: 44

Rep: Reputation: 15
Talking export command


Really a simple question for you:
i have the following configuration files:
~/.bashrc
Code:
# .bashrc
# User specific aliases and functions
# Source global definitions
if [ -f /etc/bashrc ]; then
        . /etc/bashrc
fi
# enable programmable completion features
if [ -f /etc/bash_completion ]; then
        . /etc/bash_completion
fi
and:
/etc/bashrc
Code:
# /etc/bashrc

# System wide functions and aliases
# Environment stuff goes in /etc/profile

# by default, we want this to get set.
# Even for non-interactive, non-login shells.
if [ "`id -gn`" = "`id -un`" -a `id -u` -gt 99 ]; then
	umask 002
else
	umask 022
fi

# are we an interactive shell?
if [ "$PS1" ]; then
    case $TERM in
	xterm*)
	    PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
	    ;;
	*)
	    ;;
    esac
    [ "$PS1" = "\\s-\\v\\\$ " ] && PS1="[\u@\h \W]\\$ "
    
    if [ -z "$loginsh" ]; then # We're not a login shell
        for i in /etc/profile.d/*.sh; do
	    if [ -x $i ]; then
	        . $i
	    fi
	done
    fi
fi

unset loginsh
so installed firefox and the new executable is placed in ~/firefox-installer.
My PATH is :
Code:
/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/user/bin
now i'd like to get the executable running by invoking $firefox at the shell prompt for non-login shell.
I tried
Code:
$PATH=$PATH:~/firefox-installer
$export PATH
but it works only for that shell i am in and not for newly invoked ones.
How to solve this?



Thank you!
 
Old 04-11-2005, 05:24 AM   #2
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,515

Rep: Reputation: 239Reputation: 239Reputation: 239
put the export in your ~/.bashrc
 
  


Reply



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
set/export command? blackzone Linux - Newbie 1 03-05-2005 07:11 PM
Info needed on export command Nishtya Linux - Newbie 2 07-10-2004 02:45 PM
When to use the set and when to use export command? davidas Linux - Newbie 5 03-29-2004 04:01 AM
BASH export command galalleni Slackware 4 09-08-2003 12:44 AM
Export Command choawk Linux - General 1 06-06-2003 01:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva

All times are GMT -5. The time now is 11:32 PM.

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
Open Source Consulting | Domain Registration