{"id":200455,"date":"2020-09-23T08:48:35","date_gmt":"2020-09-23T00:48:35","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=200455"},"modified":"2020-09-11T09:50:07","modified_gmt":"2020-09-11T01:50:07","slug":"ubuntu-linux-terminal","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/ubuntu-linux-terminal.html","title":{"rendered":"Ubuntu Linux\u7ec8\u7aef\u989c\u8272\u4e2a\u6027\u5316\u8bbe\u7f6e\u6280\u5de7"},"content":{"rendered":"
\u5bfc\u8bfb<\/td>\n | Linux\u7ed9\u4eba\u6700\u5927\u7684\u4f18\u70b9\u4e4b\u4e00\u5c31\u662f\u53ef\u4ee5\u6839\u636e\u4e2a\u4eba\u559c\u597d\u53bb\u5b9a\u5236\u4ee4\u81ea\u5df1\u559c\u6b22\u7684\u7cfb\u7edf\u914d\u7f6e\uff0c\u6bd4\u5982\u7ec8\u7aef\u989c\u8272\u7684\u8bbe\u7f6e\u5c31\u662f\u4e00\u4e2a\u7ecf\u5178\u4f8b\u5b50\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n \u5bf9\u4e8e\u521d\u6b21\u4f7f\u7528Ubuntu\u7684\u540c\u5b66\u4eec\uff0c\u6253\u5f00\u7ec8\u7aef\uff08\u5feb\u6377\u952e\u4e3aCtrl + Alt + T\uff09\uff0c\u5c31\u4f1a\u53d1\u73b0\u547d\u4ee4\u884c\u91cc\u7684\u7528\u6237\u540d\u3001\u4e3b\u673a\u540d\u8fd8\u662f\u547d\u4ee4\u90fd\u662f\u767d\u8272\u7684\uff0c\u5f53\u7136\uff0c\u6211\u4eec\u7528 ls \u5217\u51fa\u6587\u4ef6\u7684\u65f6\u5019\u662f\u4f1a\u591a\u4e00\u79cd\u989c\u8272\u7684\u3002\u4f46\u662f\u5bf9\u4e8e\u5f00\u53d1\u8005\u6765\u8bf4\uff0c\u8fd8\u662f\u4e0d\u591f\u9ad8\u6548\u7684\u56e0\u4e3a\u6709\u65f6\u5019\u4f60\u9700\u8981\u53bb\u51e0\u5341\u884c\u751a\u81f3\u4e0a\u767e\u884c\u4ee3\u7801\u91cc\u9762\u53bb\u627e\u4e00\u4e9b\u4f60\u8fd0\u884c\u8fc7\u7684\u547d\u4ee4\u6216\u4f60\u60f3\u8981\u7684\u4fe1\u606f\u3002\u56e0\u6b64\u5c06\u7ec8\u7aef\uff08Terminal\uff09\u914d\u8272\u4e5f\u53d8\u7684\u5f88\u91cd\u8981\u3002<\/p>\n \u672c\u6587\u64cd\u4f5c\u7684\u4f8b\u5b50\u64cd\u4f5c\u7cfb\u7edf\u4e3a\uff1aUbuntu 18.04 LTS<\/p>\n \u5bf9\u4e8e\u7528\u6237\u7684\u914d\u7f6e\uff0c\u6211\u4eec\u5e94\u8be5\u5c06\u914d\u7f6e\u4fe1\u606f\u5199\u5165~\/.bashrc\u6587\u4ef6\u3002<\/p>\n <\/p>\n 1\u3001\u989c\u8272\u914d\u7f6e<\/strong><\/span><\/div>\n \u4e3a\u4e86\u8bbe\u7f6e\u7ec8\u7aef\u989c\u8272\uff0c\u6211\u4eec\u9700\u8981\u5bf9\uff5e\/.bashrc\u6587\u4ef6\u4e2d\u7684PS1\u53d8\u91cf\u8fdb\u884c\u5b9a\u5236\u3002\u9996\u5148\u901a\u8fc7\u201cvim ~\/.bashrc\u201c\u547d\u4ee4\u6253\u5f00\u6587\u4ef6\uff0c\u627e\u5230PS1\u53d8\u91cf\u6240\u5728\u4f4d\u7f6e\uff1a<\/p>\n <\/p>\n bashrc\u6587\u4ef6\u4e2d\u7684PS1\u53d8\u91cf<\/p>\n \u4e0a\u56fe\u5c31\u662f\u6211\u4eec\u9700\u8981\u4fee\u6539\u7684\u547d\u4ee4\u884c\u63d0\u793a\u7b26\u7684\u989c\u8272\u8bbe\u7f6e\u3002<\/p>\n \u6ce8\u91ca\u6389 #force_color_prompt=yes\u3002\u5728\u989c\u8272\u6a21\u5f0f\u6253\u5f00\u7684\u60c5\u51b5\u4e0b\uff0cPS1\u53d8\u91cf\u4ee3\u8868\u7684\u5185\u5bb9\u5c31\u662f\u7528\u6237\u540d+\u4e3b\u673a\u540d+\u8def\u5f84\u540d\uff08\u957f\u8def\u5f84\uff09+ $<\/p>\n PS1='${debian_chroot:+($debian_chroot)}\\u@\\h:\\w\\$ '<\/pre>\n |