I see this a lot in terminal commands and didn't understand what does it mean. also the terminal doesn't recognize it.
I assume you're seeing this host%
in documentation. It stands for the shell prompt. ("Shell" is the program that reads the commands you type; "prompt" is the little bit of text that this program displays on your screen to say that it's ready to read your next command.)
If you look at a terminal window on your computer you'll probably see something like
my-computer-name%
on the last line, where "my-computer-name" is of course your computer's name. This is prompting you (i.e., inviting you) to type a command. So now you go and type ls
and carriage return, and the shell prints some output.
Linux documentation typically uses host%
to indicate the prompt ("host" is another name for "computer").
This host%
It's not meant to be typed: it just indicates that what follows in the document is to be typed.
I open this question because it is got me interested. I did't know what is host%
. But the answer is more easier then I was thinking.
I'v google it and found this tutorial, where we can see this magically host%
.
This is so called Shell Prompt. Thing that usually appear before each command in terminal emulator. It is usually provide some information to user. Previously it has been used to show host
name, that's why you can see host%
it some documentation and tutorials. Imagine that you have opened a few terminal sessions to a different hosts. There is a chance that you get confused and type some command to the wrong terminal. I think that's why Prompt is exists.
In Ubuntu it is usually look like this:
username@hostname:path $
Where:
username - Currently logged in user login
hostname - This host's name
path - Showing path to the folder. The current working directory, with $HOME abbreviated with a tilde
$ - End of prompt, and start of new command
You can customize Bash Prompt if you want. Here is my prompt:
22:33:16 - (~/Downloads)$
current_time - (path)$
Here is nice tutorial for customizing it
Host% is nothing but a prompt with host name (your computer name) saying that the shell is ready to accept commands. This prompt can be set to username or it can show time or date etc.
host%
it is just bash prompt. You can google about bash prompt if you don't know what is it. – c0rp Jul 20 '14 at 16:04