QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 632|回复: 1

求bash shell提示符中quot;uquot;,quot;hquot;等其他转移字

[复制链接]
发表于 2004-11-8 22:31:10 | 显示全部楼层 |阅读模式
我们知道在bash shell提示符中,\u表示当前用户,\h表示当前主机名。

还有哪些呢?哪个兄弟能够给个完整的列表?

我先贴一部分
              \t     the current time in HH:MM:SS format
              \d     the date  in  "Weekday  Month  Date"  format
              \s     the  name  of  the shell, the basename of $0
              \w     the current working directory
              \W     the basename of the current  working  directory
              \u     the uname of the current user
              \h     the hostname
              \#     the command number of this command
              \!     the history number of this command
              \$     if  the effective UID is 0, a #, otherwise a $
发表于 2004-11-9 07:02:57 | 显示全部楼层

Re: 求bash shell提示符中quot;uquot;,quot;hquot;等其他转移字

[quote:ae8551c7eb="cowboy"]哪个兄弟能够给个完整的列表?[/quote]
你的列表差不多已经全了 :-)

这里有以前讨论过的一个问题,关于 Shell 提示符:
http://www.linuxfans.org/nuke/modules.php?name=Forums&file=viewtopic&t=69879&start=0&postdays=0&postorder=asc&highlight=
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-9-18 17:05 , Processed in 0.038515 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表