Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

treycaliva

macrumors newbie
Original poster
Jul 21, 2008
2
0
I'm getting a very strange terminal problem. On my command-line, where you'd usually see "localhost:~" or your computer name, I'm getting "47:~".

I've been playing around with a Ruby on Rails installation, do you think this would have anything to do with it?
 
This is normal if your computer is connected to a public Wi-Fi network, for example. Your prompt in the Terminal will take on a new name instead of localhost. Certain kinds of servers can affect this too, if they're running on your computer and you're connected to them.
 
its likely normal. If you check your environment settings in terminal, I'm willing to bet that the line for PS1 looks something like this:
PS1='\h:\W\$'

this expands to the following:

hostname:basename of current working directory$

unless you're signed in as somebody with UID 0 (i.e. root), then it'll be:

hostname:basename of current working directory#

All these can be found in the man page for the shell you're using (I checked both sh and bash, and they're in there), under the "prompting" section. Give it a read, and find ways to customize your prompt.. they can be made to look pretty cool, and there's lots of useful stuff that you can display on each prompt as well (like the date/time, username, etc).

By the way, you can view your prompt setting by typing 'set' at the prompt, and look for the lines that say "PS1" through "PS4".
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.