.\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "PROMPT_HOSTNAME" "1" "Nov 13, 2025" "4.2" "fish-shell" .SH NAME prompt_hostname \- print the hostname, shortened for use in the prompt .SH SYNOPSIS .nf \fBprompt_hostname\fP .fi .sp .SH DESCRIPTION .sp \fBprompt_hostname\fP prints a shortened version the current hostname for use in the prompt. It will print just the first component of the hostname, everything up to the first dot. .SH EXAMPLES .INDENT 0.0 .INDENT 3.5 .sp .EX function fish_prompt echo \-n (whoami)@(prompt_hostname) (prompt_pwd) \(aq$ \(aq end .EE .UNINDENT .UNINDENT .INDENT 0.0 .INDENT 3.5 .sp .EX # The machine\(aqs full hostname is foo.bar.com >_ prompt_hostname foo .EE .UNINDENT .UNINDENT .SH COPYRIGHT fish-shell developers .\" Generated by docutils manpage writer. .