{"id":494,"date":"2008-06-10T23:15:38","date_gmt":"2008-06-10T14:15:38","guid":{"rendered":"http:\/\/ecpplus.net\/weblog\/?p=494"},"modified":"2020-05-24T23:22:37","modified_gmt":"2020-05-24T14:22:37","slug":"start_zsh","status":"publish","type":"post","link":"https:\/\/ecpplus.net\/weblog\/start_zsh\/","title":{"rendered":"Mac\u3067zsh\u3092\u4f7f\u3063\u3066\u307f\u3088\u3046\u3068\u601d\u3063\u305f"},"content":{"rendered":"<p>\u3000Mac\u3067zsh\u3092\u4f7f\u3063\u3066\u307f\u305f\u3002<a href=\"http:\/\/journal.mycom.co.jp\/column\/zsh\/\">\u6f22\u306ezsh<\/a> \u3063\u3066\u3044\u3046\u306e\u3092\u53c2\u8003\u306b\u8a2d\u5b9a\u3057\u3066\u307f\u305f\u3002<\/p>\n<p>\u3000\u307e\u305a\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30ed\u30b0\u30a4\u30f3\u30b7\u30a7\u30eb\u3092\u5909\u66f4\u3059\u308b\u3002<\/p>\n<p>\u3000\u30b7\u30b9\u30c6\u30e0\u74b0\u5883\u8a2d\u5b9a -> \u30a2\u30ab\u30a6\u30f3\u30c8 -> \u81ea\u5206\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3067 Ctrl + Click -> \u8a73\u7d30\u30aa\u30d7\u30b7\u30e7\u30f3 -> \u30ed\u30b0\u30a4\u30f3\u30b7\u30a7\u30eb\u3092 \/bin\/zsh<\/p>\n<p>\u3000\u3068\u3059\u308c\u3070\u304ak\u3002<\/p>\n<p>\u3000\u4e0a\u8a18URL\u3092\u3082\u3068\u306b\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u66f8\u3044\u3066\u307f\u305f\u3051\u3069\u3001\u3088\u304f\u5206\u304b\u3063\u3066\u306a\u3044\u3002\u30c7\u30d5\u30a9\u3067 Bash \u306e Ctrl + R \u307f\u305f\u3044\u306a\u611f\u3058\u306a\u8a2d\u5b9a\u306a\u3093\u3060\u3051\u3069\u3001\u6163\u308c\u305f\u3089\u901f\u305d\u3046\u3002\u6163\u308c\u308b\u307e\u3067\u30b9\u30c8\u30ec\u30b9\u306b\u306a\u308a\u305d\u3046\u3002<\/p>\n<pre lang=\"bash\">autoload colors\ncolors\ncase ${UID} in\n0)\n  PROMPT=\"%B%{${fg[red]}%}%\/#%{${reset_color}%}%b \"\n  PROMPT2=\"%B%{${fg[red]}%}%_#%{${reset_color}%}%b \"\n  SPROMPT=\"%B%{${fg[red]}%}%r is correct? [n,y,a,e]:%{${reset_color}%}%b \"\n  [ -n \"${REMOTEHOST}${SSH_CONNECTION}\" ] &&\n    PROMPT=\"%{${fg[white]}%}${HOST%%.*} ${PROMPT}\"\n  ;;\n*)\n  PROMPT=\"%{${fg[red]}%}%\/%%%{${reset_color}%} \"\n  PROMPT2=\"%{${fg[red]}%}%_%%%{${reset_color}%} \"\n  SPROMPT=\"%{${fg[red]}%}%r is correct? [n,y,a,e]:%{${reset_color}%} \"\n  [ -n \"${REMOTEHOST}${SSH_CONNECTION}\" ] &&\n    PROMPT=\"%{${fg[white]}%}${HOST%%.*} ${PROMPT}\"\n  ;;\nesac\n\n\nexport LSCOLORS=gxfxcxdxbxegedabagacad\nalias ls='ls -G'\nzstyle ':completion:*' list-colors ${(s.:.)LSCOLORS}\nautoload -U compinit\ncompinit\nPROMPT=\"%\/%% \"\nPROMPT2=\"%_%% \"\nSPROMPT=\"%r is correct? [n,y,a,e]: \"\n\n\ncase \"${TERM}\" in\nkterm*|xterm)\n  precmd() {\n    echo -ne \"\\033]0;${USER}@${HOST%%.*}:${PWD}\\007\"\n  }\n  ;;\nesac\n\n# \u5c65\u6b74\u309210000\u4ef6\u4fdd\u5b58\u3059\u308b\nHISTFILE=~\/.zsh_history\nHISTSIZE=10000\nSAVEHIST=10000\nsetopt hist_ignore_dups     # ignore duplication command history list\nsetopt share_history        # share command history data\n\n# vi\u306e\u30ad\u30fc\u30d0\u30a4\u30f3\u30c9\u306b\u306a\u308b\nbindkey -v\n\n# \u5c65\u6b74\u691c\u7d22 Ctrl+P, Ctrl+N \u3067\u305f\u3069\u308c\u308b\nautoload history-search-end\nzle -N history-beginning-search-backward-end history-search-end\nzle -N history-beginning-search-forward-end history-search-end\nbindkey \"^P\" history-beginning-search-backward-end\nbindkey \"^N\" history-beginning-search-forward-end\n\n# cd \u304c pushd \u306b\u306a\u308b\nsetopt auto_pushd\n\n# \u81ea\u52d5\u88dc\u5b8c\u8a2d\u5b9a\nautoload predict-on\npredict-on\n\n# alias\u8a2d\u5b9a<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u3000Mac\u3067zsh\u3092\u4f7f\u3063\u3066\u307f\u305f\u3002\u6f22\u306ezsh \u3063\u3066\u3044\u3046\u306e\u3092\u53c2\u8003\u306b\u8a2d\u5b9a\u3057\u3066\u307f\u305f\u3002 \u3000\u307e\u305a\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30ed\u30b0\u30a4\u30f3\u30b7\u30a7\u30eb\u3092\u5909\u66f4\u3059\u308b\u3002 \u3000\u30b7\u30b9\u30c6\u30e0\u74b0\u5883\u8a2d\u5b9a -> \u30a2\u30ab\u30a6\u30f3\u30c8 -> \u81ea\u5206\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3067 Ctrl + Click ->  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[43],"tags":[12,11],"class_list":["post-494","post","type-post","status-publish","format-standard","hentry","category-development","tag-mac","tag-tool"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/posts\/494","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/comments?post=494"}],"version-history":[{"count":1,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/posts\/494\/revisions"}],"predecessor-version":[{"id":2207,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/posts\/494\/revisions\/2207"}],"wp:attachment":[{"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/media?parent=494"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/categories?post=494"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ecpplus.net\/weblog\/wp-json\/wp\/v2\/tags?post=494"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}