LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 08-17-2004, 02:16 PM   #1
amnesty_puppy
Member
 
Registered: Aug 2004
Location: Britain
Distribution: Gentoo
Posts: 52

Rep: Reputation: 15
Shell prompts and keymaps


Slack 10 + Xfce

= Using the bash shell, is there a way to change the prompt text, like DOS where you can add current path and other things.

= How do I change the keymap - is there a text file containing all the current bindings? Alternatively how would I load the keymap for a UK keyboard? The default US map has the " and @ swapped, among other things.

Thanks.
 
Old 08-17-2004, 02:33 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Hi, and welcome to LQ!

There sure is .... it's an environment variable called
PS1 ... man bash for details.

And number two: there's the loadkeys command
if you're in the shell .. for X you want to edit the
XF86Config, find us and replace it with uk

If you mention your distro you can get more help,
btw, many things depend on the distro!


Cheers,
Tink
 
Old 08-17-2004, 03:02 PM   #3
amnesty_puppy
Member
 
Registered: Aug 2004
Location: Britain
Distribution: Gentoo
Posts: 52

Original Poster
Rep: Reputation: 15
Thanks, just trawled through the bash man pages. My distros at the top of my original post (Slackware 10 with Xfce).

Another question: Is there a way to "su" in x?
 
Old 08-17-2004, 03:09 PM   #4
scuzzman
Senior Member
 
Registered: May 2004
Location: Hilliard, Ohio, USA
Distribution: Slackware, Kubuntu
Posts: 1,851

Rep: Reputation: 47
Quote:
Another question: Is there a way to "su" in x?
Yes & No...
You can login as root and 'startx' if you'd like, but it is firmly not recoomended. What you'll want to do, is su, then, as root, start eny programs you need thru the command line.
 
Old 08-17-2004, 03:13 PM   #5
amnesty_puppy
Member
 
Registered: Aug 2004
Location: Britain
Distribution: Gentoo
Posts: 52

Original Poster
Rep: Reputation: 15
whoa, don't run X as root? I've been doing that for a lot of things, is there some major security problem?
 
Old 08-17-2004, 03:16 PM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Quote:
Originally posted by amnesty_puppy
Thanks, just trawled through the bash man pages. My distros at the top of my original post (Slackware 10 with Xfce).
doh :}
tired is all I can say ;)

Quote:
Another question: Is there a way to "su" in x?
Ummm ... running an X app as root within the
normal users X-session?

Several ways ...
http://www.linuxquestions.org/questi...hreadid=202463



Cheers,
Tink
 
Old 08-17-2004, 03:26 PM   #7
amnesty_puppy
Member
 
Registered: Aug 2004
Location: Britain
Distribution: Gentoo
Posts: 52

Original Poster
Rep: Reputation: 15
Cheers chaps.

Read somewhere to edit bashrc file but I can't seem to find it, no /etc/bashrc /etc/profile and no help from find either.
 
Old 08-17-2004, 05:02 PM   #8
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Slack is minimalist ... it doesn't give you a pre-fabbed
~/.bashrc
Create one :)


Cheers,
Tink
 
Old 08-17-2004, 06:52 PM   #9
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 54
With some text editors is is hidden /.bashrc if you use xedit or mc it is not hidden.If you do a cd then ls you won't see it but if you do cd then ls -a you will.I had a heck of a time finding it!
also here is a nice script for a cool prompt and some nice colors for ls http://www.pablotron.org/software/bash_tweaks/ Do not do it as root and use a dark background and you can edit it or remove it if you don't like it,I use it because I'm to lazy to write it all out.

Last edited by comprookie2000; 08-17-2004 at 07:00 PM.
 
  


Reply


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
Changing keymaps in xorg.conf. jens Slackware 3 09-22-2005 12:04 PM
Keymaps!! egz Slackware - Installation 2 05-30-2005 02:20 PM
Gnome problem with keymaps crazydemon Linux - Software 1 01-03-2005 04:24 PM
Shell Prompts and root ls colouring iantri Slackware 10 09-11-2003 08:48 PM
Fluxbox keymaps fuxored Linux - General 2 06-02-2002 03:48 PM


All times are GMT -5. The time now is 12:20 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration