{"id":295470,"date":"2025-01-09T12:16:22","date_gmt":"2025-01-09T04:16:22","guid":{"rendered":"https:\/\/lrxjmw.cn\/mqdjzwjwzjhj.html"},"modified":"2025-01-09T12:16:22","modified_gmt":"2025-01-09T04:16:22","slug":"mqdjzwjwzjhj","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/mqdjzwjwzjhj.html","title":{"rendered":"Mac\u542f\u52a8\u52a0\u8f7d\u6587\u4ef6\u4f4d\u7f6e\u53ca\u73af\u5883\u53d8\u91cf\u8bbe\u7f6e\u6307\u5357\uff1aBourne Shell\u4e0eC Shell\u8be6\u89e3"},"content":{"rendered":"
Mac\u542f\u52a8\u52a0\u8f7d\u6587\u4ef6\u4f4d\u7f6e\uff08\u53ef\u8bbe\u7f6e\u73af\u5883\u53d8\u91cf\uff09<\/p>\n
-------------------------------------------------------<\/p>\n
\uff081\uff09\u9996\u5148\u8981\u6653\u5f97\u4f60\u4f7f\u7528\u7684MacOSX\u662f\u54ea\u4e9b\u6837\u7684Shell<\/a>\uff0c\u4f7f\u7528\u547d\u4ee4<\/a><\/p>\n echo$SHELL<\/p>\n \u5047\u82e5\u8f93\u51fa\u7684\u662f\uff1acsh\u6216\u5219\u662ftcshlinux \u4fee\u6539\u73af\u5883\u53d8\u91cf \u91cd\u542f\u751f\u6548<\/strong>\uff0c\u8fd9\u4e48\u4f60\u7528\u7684\u5c31\u662fCShell\u3002<\/p>\n \u5047\u82e5\u8f93\u51fa\u7684\u662f\uff1abashlinux \u4fee\u6539\u73af\u5883\u53d8\u91cf \u91cd\u542f\u751f\u6548<\/strong>\uff0csh\uff0czsh\uff0c\u8fd9\u4e48\u4f60\u7684\u7528\u7684\u53ef\u80fd\u5c31\u662fBourneShell\u7684\u4e00\u4e2a\u53d8\u79cd\u3002<\/p>\n MacOSX10.2\u4e4b\u524d\u9ed8\u8ba4\u7684\u662fCShell\u3002<\/p>\n MacOSX10.3\u4ee5\u540e\u9ed8\u8ba4\u7684\u662fBourneShell\u3002<\/p>\n <\/p>\n \uff082\uff09\u5047\u5982\u662fBourneShell\u3002<\/p>\n \u8fd9\u4e48\u4f60\u53ef\u4ee5\u628a\u4f60\u8981\u6dfb\u52a0\u7684\u73af\u5883\u53d8\u91cf\u6dfb\u52a0\u5230\u4f60\u4e3b\u76ee\u5f55\u4e0b\u8fb9\u7684.profile\u6216\u5219.bash_profile\uff0c\u5047\u5982\u5b58\u5728\u6ca1\u6709\u5173\u7cfb\u6dfb\u52a0\u8fdb\u53bb\u5373\u53ef\uff0c\u5047\u5982\u6ca1\u6709\u751f\u6210\u4e00\u4e2a\u3002<\/p>\n Mac\u914d\u7f6e\u73af\u5883\u53d8\u91cf\u7684\u5730\u65b9<\/p>\n 1.\/etc\/profile\uff08\u5efa\u8bae\u4e0d\u66f4\u6539\u8fd9\u4e2a\u6587\u4ef6\uff09<\/p>\n \u5168\u5c40\uff08\u516c\u6709\uff09\u914d\u7f6e\uff0c\u4e0d\u7ba1\u662f\u90a3\u4e2a\u7528\u6237\uff0c\u767b\u9646\u65f6\u5c31\u4f1a\u8bfb\u53d6\u8be5\u6587\u4ef6\u3002<\/p>\n 2.\/etc\/bashrc\uff08\u901a\u5e38\u5728\u8fd9\u4e2a\u6587\u4ef6\u4e2d\u6dfb\u52a0\u7cfb\u7edf\u7ea7\u73af\u5883\u53d8\u91cf\uff09<\/p>\n \u5168\u5c40\uff08\u516c\u6709\uff09\u914d\u7f6e\uff0cbashshell\u6267\u884c\u65f6\uff0c\u4e0d\u7ba1\u662f\u4f55\u79cd\u65b9\u6cd5linux\u67e5\u770b\u64cd\u4f5c\u7cfb\u7edf\uff0c\u5c31\u4f1a\u8bfb\u53d6\u6b64\u6587\u4ef6\u3002<\/p>\n 3.~\/.bash_profile\uff08\u901a\u5e38\u5728\u8fd9\u4e2a\u6587\u4ef6\u4e2d\u6dfb\u52a0\u7528\u6237\u7ea7\u73af\u5883\u53d8\u91cf\uff09<\/p>\n <\/p>\n \u6bcf\u4f4d\u7528\u6237\u90fd\u53ef\u4f7f\u7528\u8be5\u6587\u4ef6\u8f93\u5165\u4e13\u7528\u4e8e\u81ea\u5df1\u4f7f\u7528\u7684shell\u4fe1\u606f,\u5f53\u7528\u6237\u767b\u5165\u65f6,\u8be5\u6587\u4ef6\u4ec5\u4ec5\u6267\u884c\u4e00\u6b21!<\/p>\n MAC\u66f4\u6539host\u6587\u4ef6<\/p>\n -------------------------------------------------------<\/p>\n sudovi\/etc\/hosts<\/p>\n linux\u4e0b\u67e5\u770b\u548c\u6dfb\u52a0PATH\u73af\u5883\u53d8\u91cf<\/p>\n ==============================================<\/p>\n PATH\u7684\u683c\u5f0f\u4e3a\uff1a<\/p>\n -------------------------------------------------------<\/p>\n PATH=$PATH:<\/p>\n :------:<\/p>\n <\/p>\n linux\u73af\u5883\u914d\u7f6e\uff0c\u4e2d\u95f4\u7528\u9017\u53f7\u9694\u5f00\u3002<\/p>\n \u6dfb\u52a0PATH\u73af\u5883\u53d8\u91cf\uff1a<\/p>\n -------------------------------------------------------<\/p>\n