diff --git a/doc_src/read.txt b/doc_src/read.txt index b85b5fd8f..d69d715b7 100644 --- a/doc_src/read.txt +++ b/doc_src/read.txt @@ -9,8 +9,8 @@ The read builtin causes fish to read one line from standard input and store the result in one or more environment variables. - -c CMD or --command=CMD specifies that the initial string in the interactive mode command buffer should be CMD. -- -e or --export specifies that the variables will be exported to subshells. - -g or --global specifies that the variables will be made global. +- -l or --local specifies that the variables will be made local. - -m NAME or --mode-name=NAME specifies that the name NAME should be used to save/load the history file. If NAME is fish, the regular fish history will be available. - -p PROMPT_CMD or --prompt=PROMPT_CMD specifies that the output of the shell command PROMPT_CMD should be used as the prompt for the interactive mode prompt. The default prompt command is set_color green; echo read; set_color normal; echo "> ". - -s or --shell Use syntax highlighting, tab completions and command termination suitable for entering shellscript code diff --git a/reader.cpp b/reader.cpp index 29645d74b..ba275f54d 100644 --- a/reader.cpp +++ b/reader.cpp @@ -118,7 +118,7 @@ commence. fish specific commands, meaning it will work even if fish is not installed. This is used by read_i. */ -#define DEFAULT_PROMPT L"echo \"$USER@\"; hostname|cut -d . -f 1; echo \" \"; pwd; printf '> ';" +#define DEFAULT_PROMPT L"echo -n \"$USER@\"(hostname|cut -d . -f 1)' '(pwd)'> '" /** The name of the function that prints the fish prompt