PS1 issue between Solaris and Ubuntu


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers PS1 issue between Solaris and Ubuntu
Prev   Next
# 1  
Old 02-16-2011
PS1 issue between Solaris and Ubuntu

I'm relatively new to *nix, and have been playing around with my .profile. I've been using ksh as my shell. Specifically I've been playing with my PS1 prompt, and trying to make it look uniform across Ubuntu and Solaris. I've posted what I currently have below.

Code:
HOSTNAME=$(hostname) ; export HOSTNAME 
PS1='$USER@$HOSTNAME:$PWD> ' ; export PS1



Currently this works fine in Solaris 10 and 11 express if I connect via ssh or open a terminal on a console session, and with Ubuntu 10.04 and 10.10 if I connect via ssh - the problems is when I'm on an Ubuntu console (I've switched my main pc to ubuntu as a desktop os) all I get is my ksh "$" prompt. If I source my .profile then the PS1 prompt will work.

I've been scratching my head at this and finally decided to post - I'm sure it's a pretty simple/obvious issue I'm overlooking.

I've searched through these forums but didn't find a post that matched my issue, forgive me if I missed a post that addresses this.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Help changing the PS1 prompt in Solaris

Hi, I need help changing PS1 in Solaris. I tried this: MYPROMPT="> " PS1=$LOGNAME@$HOSTNAME:${PWD}$MYPROMPT (NOT SURE WHY IT'S HIGHLIGHTED HERE) export PS1 My problem is that $PWD is not working, when I get the prompt and I change directories, the prompt is not displaying the current... (17 Replies)
Discussion started by: curiousmal
17 Replies

2. Shell Programming and Scripting

Issue with Single Quotes and Double Quotes for prompt PS1

Hi, Trying to change the prompt. I have the following code. export PS1=' <${USER}@`hostname -s`>$ ' The hostname is not displayed <abc@`hostname -s`>$ uname -a AIX xyz 1 6 00F736154C00 <adcwl4h@`hostname -s`>$ If I use double quotes, then the hostname is printed properly but... (3 Replies)
Discussion started by: bobbygsk
3 Replies

3. Ubuntu

ubuntu 9.10 virtual console issue

i'm having a frustrating issue with virtual consoles on my ubuntu 9.10 setup i was having trouble accessing the virtual consoles at all (no visible display) so i installed XDM and set it as the default X login manager) now when i hit ctl-alt F1-F6 instead of the usual getty (login prompt) i get... (0 Replies)
Discussion started by: hopper195
0 Replies

4. Ubuntu

Installation issue while installing ubuntu

Hi All As i m trying to install ubuntu on my virtual PC where h/w confg is as 5GB didk n 512 mb RAm. after selecting mode option, and after pressing F6 after that screen shows some msg. And not goes to next step. What is the problem n wht i shall do?? Please provide me solution (3 Replies)
Discussion started by: sunray
3 Replies

5. IP Networking

Ubuntu LAN connectivity issue

System: Dell Desktop w/ 2 SATA drives running Ubuntu 9.10 that uses 2 ethernet cards, 1 for internet connectivity and another to interface the machine with a high voltage power supply which supports ssh and EPICS controls. Second Ethernet card is connected to a NetGear WNR3500 router, the VME... (0 Replies)
Discussion started by: henslewm
0 Replies

6. Programming

Ubuntu 9.04 issue

i have been tyring to install the Ubuntu OS 9.04 ,some how i failed to install it. i actually downloaded the OS from Download Ubuntu | Ubuntu i got the image file i tried to burn it by using nero, it susscessfully burned the image but when i insert the cd into drive and restart my system... (5 Replies)
Discussion started by: MrUser
5 Replies

7. Ubuntu

Ubuntu OS 9.04 issue ..

i have been tyring to install the Ubuntu OS 9.04 ,some how i failed to install it. i actually downloaded the OS from Download Ubuntu | Ubuntu i got the image file i tried to burn it by using nero, it susscessfully burned the image but when i insert the cd into drive and restart my system its... (1 Reply)
Discussion started by: MrUser
1 Replies

8. Ubuntu

Ubuntu Graphic Quality Issue?

Okay I have my computer dual booted with Ubuntu 9.04 and Windows Vista, when I play a game on Vista such as Soldier Front or Quake its smooth and very enjoyable, but when I try to get a simple game such as Scorched 3D, its glitchy, choppy, and the background seeps through to the game (I get a... (9 Replies)
Discussion started by: phoxly
9 Replies

9. IP Networking

Issue with /etc/hosts file under ubuntu

I think terminal outpu is better than long words so: I rebooted my laptop but no success... It's the same for all entry i added... Any ideas ? PS: I'm under ubuntu 9.0.4 edit: hostnames can't start with a number, using c4507 for example works. (0 Replies)
Discussion started by: nekkro-kvlt
0 Replies

10. Ubuntu

This an Ubuntu or Dell issue?

I have a dell poweredge sc430 (what ever that is). Came cheap with an 80 gig sata hard drive. So maybe a year later I bought a 250 gig sata drive for backup (with rsynch from cron). Rsynch works fine. But now the machine won't reboot without me manually pressing the F1 key. I see a... (3 Replies)
Discussion started by: salmobytes
3 Replies
Login or Register to Ask a Question
play_midi(3alleg4)						  Allegro manual						play_midi(3alleg4)

NAME
play_midi - Starts playing the specified MIDI file. Allegro game programming library. SYNOPSIS
#include <allegro.h> int play_midi(MIDI *midi, int loop); DESCRIPTION
Starts playing the specified MIDI file, first stopping whatever music was previously playing. If the loop flag is set to non-zero, the data will be repeated until replaced with something else, otherwise it will stop at the end of the file. Passing a NULL pointer will stop what- ever music is currently playing. RETURN VALUE
Returns non-zero if an error occurs (this may happen if a patch-caching wavetable driver is unable to load the required samples, or at least it might in the future when somebody writes some patch-caching wavetable drivers :-) SEE ALSO
install_sound(3alleg4), load_midi(3alleg4), play_looped_midi(3alleg4), stop_midi(3alleg4), midi_pause(3alleg4), midi_seek(3alleg4), midi_pos(3alleg4), midi_time(3alleg4), midi_msg_callback(3alleg4), exmidi(3alleg4) Allegro version 4.4.2 play_midi(3alleg4)