LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-03-2010, 01:03 PM   #1
tpresa
LQ Newbie
 
Registered: May 2009
Posts: 4

Rep: Reputation: 0
adding sth. to all users' PATH variable (sudo included)


Hello,

I've installed rubygems on ubuntu, but it has a known issue that the rubygems' bin/ directory is not in the PATH. I know about exporting the PATH variable, and adding it to .bashrc, but I'd like to configure it so that every user has it on his PATH, even if he tries to run it with sudo. Where should I export the PATH variable then?
 
Old 08-03-2010, 02:40 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
/etc/bashrc (assuming they're using bash shell)

/etc/profile (ksh)

/etc/login (csh)
 
Old 08-03-2010, 03:16 PM   #3
tpresa
LQ Newbie
 
Registered: May 2009
Posts: 4

Original Poster
Rep: Reputation: 0
It didn't work for sudo. I'm on bash and on Ubuntu, if that matters. I've added to /etc/bash.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
Sudo path variable error andrewbonney Linux - Newbie 2 05-29-2010 03:07 AM
Adding a executable file $PATH Variable ajeet@linux Solaris / OpenSolaris 3 03-18-2010 12:30 PM
Setting PATH variable for new users vhn Linux - General 3 01-30-2010 08:37 AM
Adding Java to root users PATH? infornography Linux - Newbie 5 05-26-2005 07:49 AM
Adding JavaVM to PATH variable? Crickit Linux - Software 3 05-06-2003 03:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:38 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