Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
A Few Things to Make Life Easier
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
Quantumstate
Apprentice
Apprentice


Joined: 26 May 2004
Posts: 270
Location: Dallas

PostPosted: Fri Jun 11, 2004 5:56 pm    Post subject: A Few Things to Make Life Easier Reply with quote

Withdrawn.

Last edited by Quantumstate on Sun Jun 13, 2004 5:08 pm; edited 1 time in total
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Fri Jun 11, 2004 7:50 pm    Post subject: Re: A Few Things to Make Life Easier Reply with quote

Quantumstate wrote:
Those migrating from other distros to 2004.1 will often end up with a dead-basic prompt like:
bash-2.05b#


That will only happen when the shell isn't a login shell. Don't use plain su, use
Code:
su -
The trailing dash ensures the shell is a login shell. Voila, problem solved.
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 20067

PostPosted: Fri Jun 11, 2004 7:55 pm    Post subject: Reply with quote

Moved from Installing Gentoo.
_________________
Quis separabit? Quo animo?
Back to top
View user's profile Send private message
gtaluvit
Tux's lil' helper
Tux's lil' helper


Joined: 09 Aug 2003
Posts: 135
Location: Columbia, MD

PostPosted: Fri Jun 11, 2004 8:05 pm    Post subject: Reply with quote

When you create a new user, it should copy .bashrc and .bash_login from /etc/skel. If you're migrating from another distro, you can cp those files from there. That will give you what gentoo expects you to have and not this custom stuff. :P
_________________
I'm out of bed and dressed, what more do you want?
Back to top
View user's profile Send private message
lazarusrat
Guru
Guru


Joined: 17 Jul 2002
Posts: 305
Location: Lafayette, IN

PostPosted: Fri Jun 11, 2004 8:07 pm    Post subject: Re: A Few Things to Make Life Easier Reply with quote

Quantumstate wrote:
Code:
...
#Don't clog up .bash_history with useless commands
HISTIGNORE=l:ls:ll:la:cd:pwd
...

If you want to keep your bash_history nice and clean, it's also handy to set HISTCONTROL:
man bash wrote:
HISTCONTROL
If set to a value of ignorespace, lines which begin with a space character are not entered on the history list. If set to a value of ignoredups, lines matching the last history line are not entered. A value of ignoreboth combines the two options. If unset, or if set to any other value than those above, all lines read by the parser are saved on the history list, subject to the value of HISTIGNORE. This variable's function is superseded by HISTIGNORE. The second and subsequent lines of a multi-line compound command are not tested, and are added to the history regardless of the value of HISTCONTROL.

_________________
obpiper: pipe menu generator for openbox
obtheme: pipe menu to switch openbox themes
Back to top
View user's profile Send private message
Quantumstate
Apprentice
Apprentice


Joined: 26 May 2004
Posts: 270
Location: Dallas

PostPosted: Sat Jun 12, 2004 12:31 pm    Post subject: Re: A Few Things to Make Life Easier Reply with quote

moocha wrote:

That will only happen when the shell isn't a login shell. Don't use plain su, use
Code:
su -
The trailing dash ensures the shell is a login shell. Voila, problem solved.


Actually, the basic prompt has happened to numerous of us, logging in straight as root. Because for some reason, .bashrc is not in in /root with 2004.1. I imagine this will be corrected, but that's why I specified this release.
Back to top
View user's profile Send private message
vdboor
Guru
Guru


Joined: 03 Dec 2003
Posts: 592
Location: The Netherlands

PostPosted: Sat Jun 12, 2004 1:52 pm    Post subject: Reply with quote

I've actually switched my .bashrc and .bash_profile to make my prompt work:

.bashrc:
Code:

# bash startup setup

[ -f ~/.bash_profile ] && . ~/.bash_profile

source /etc/profile


.bash_profile:
Code:
#This file is sourced by bash when you log in interactively.

alias umod='umod -v -b /opt/unreal-tournament'
alias emerge-mask='ACCEPT_KEYWORDS="~x86" emerge'

alias flag="cat /usr/portage/profiles/use.desc | grep"
alias xerrors='grep -E "\((EE|WW)\)" /var/log/Xorg.0.log'


You'll get the idea ;)

Now I can use "su" to become root in the current directory, and "su -" to start a root-login session. :)

Furthermore, I have this at the end of my /etc/profile:
Code:
for script in /etc/profile.d/*.sh
do
    if [ -x "$script" ]; then
        source "$script"
    fi
done

I noticed this in Slackware. It runs all *.sh scripts in /etc/profile.d if they are made executable..


...perhaps this is a suggestion for every gentoo default install?
_________________
The best way to accelerate a windows server is by 9.81M/S²
Linux user #311670 and Yet Another Perl Programmer

[ screenies | Coding on KMess ]
Back to top
View user's profile Send private message
Fanatic
Apprentice
Apprentice


Joined: 02 May 2004
Posts: 173
Location: Stocktown

PostPosted: Sun Jun 13, 2004 1:01 am    Post subject: Reply with quote

Well i don't have such a basic prompt in the framebuffer, but i would like my aterm to have such settings so that it looks something like

user@linux dir $:

I imagine that it's something I should edit in .Xdefaults, but i'm not too sure.

EDIT: to have a such a login prompt add:

Code:

aterm*loginShell:          true


Last edited by Fanatic on Mon Jun 14, 2004 5:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
placeholder
Advocate
Advocate


Joined: 07 Feb 2004
Posts: 2500

PostPosted: Sun Jun 13, 2004 1:34 am    Post subject: Reply with quote

Remember, not everyone uses kwrite so it would be more appropriate to write use your favorite editor such as <list of editors> to edit <file>. Just a tip for when writing guides, because there are tons of people out there that don't use KDE or the same editor that you do. :wink:
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum