Minimalistic, powerful and extremely customizable Zsh prompt
æå¼·ã®ãã¹ããªè£å®ãæ±ã㦠ã·ã§ã«ãã¹ããªã«ä¸æºãæã£ã¦ããã®ã§èªä½ãã¾ãããä»ã®èªåã«ã¨ã£ã¦ã¯å¿ è¦ãªæ©è½ãçãè¾¼ãã§ãã¦ä¾¿å©ã«ä½¿ãã¦ãã¾ããã誰ãã«ã¨ã£ã¦ã¯ããããã¯æ°ã«æå¾ã®èªåã«ã¨ã£ã¦ã¯ããããæå¼·ãããªããããããªãã§ãã 以åãã®ãããªã¨ã³ããªãæ¸ãã¾ããã www.tellme.tokyo ãã®ãããã (ãããã£ã¨åãã) ã·ã§ã«ã®ãã¹ããªè£å®ã«ä¸æºãæã£ã¦ãã¾ããã åç´ã«ããã©ã«ãã® C-r ã ã¨ç®çã®ãã®ãæ¢ãã¥ãã ä¾ãã°ã³ãã³ãåã®ä¸é¨ã ãã ã¨ãã¤ãºãå¤ããã ãã©ãã£ã¬ã¯ããªã¯è¦ãã¦ããããããã§ããã£ã«ã¿ããããã¨ã ä»ã«ãè²ã ãã£ã¦ (ãã®çç±ã«ã¤ãã¦å ã®ã¨ã³ããªãè¦ã¦ãããã¨ãã¦) zsh-history ã¨ãããã¼ã«ãæ¸ãã¾ããã GitHub - b4b4r07/zsh-history: A plugin for zsh history extended
ãããã¨ã®9å²ã¯ä»¥ä¸ã®å 容ã§ãã zsh ã® vcs_info ã«ç¬èªã®å¦çã追å ã㦠stash æ°ã¨ã push ãã¦ããªã件æ°ã¨ãä½ã§ã表示ãã èªåã®ç°å¢ã§åä½ããããã¨ããã¨ãã«è»½ãããã£ãã®ã§è¨è¼ãã¦ããã RPROMPTãããªãã¦PROMPTã«è¡¨ç¤ºãããã¨ããå ´å åç §å ã®ãµã¤ãã ã¨ãgitã®ã¹ãã¼ã¿ã¹ãªãããã¯RPROMPTã«è¡¨ç¤ºã§ãããWindowsã§Posh-Git使ã£ã¦ãè¦ã¨ãã¦ã¯PROMPTã®å³ç«¯ã«è¡¨ç¤ºãããã¨ããã ã¨ããããã§ãã®ããã«ãã¦ã¿ã¾ããããã®ã¾ã¾ãããã¨ããã¨è²ã®æå®ã¨ããã¨ã¹ã±ã¼ãé£ãã£ã¦ãã®ã¾ã¾(%F{yellow}~%fã¿ããã«)表示ããã¦ãã¾ãã®ã§ãããã«æ°ãã¤ãã¾ãããã 表示ã«ã¯psvarã使ãã¾ãã function _update_vcs_info_msg() { psvar=() LANG=en_US.UTF-8 vcs_info
zsh 㧠Git 使ã£ã¦ã人ã¯ããã³ããã«ãã©ã³ãåã¨ãã表示ãã¦ã人ãå¤ãã¨æãã zsh ã«æ¨æºã§å ¥ã£ã¦ã vcs_info ã£ã¦ããã®ã使ãã¨ã ãããããæãã«ã§ãããã ãã©ãã§ããªããã¨ãå½ç¶ããã ä¾ãã° stash ããæ°ã®è¡¨ç¤ºã«ã¯å¯¾å¿ãã¦ããªãã®ã§ãèªåã§ç¡çç¢çãªæã㧠Git ã³ãã³ããå¼ã³åºãã¦ããã³ããã«è¡¨ç¤ºãã¦ã人ãããã¨æãã ã§ã zsh 4.3.11 ããããã vcs_info ã« Hooks ã¨ããã®ã追å ããã¦ãå ã®æ©è½ã«èªåã§å¦çã追å ã§ããããã«ãªã£ã¦ããããã使ãã¨å¥½ããªããã«ã«ã¹ã¿ãã¤ãºã§ããããã«ãªãã®ã§ç´¹ä»ããã ãã®è¨äºã§ã§ããããã«ãªãã㨠ãããªãã¨ãããã³ããã«è¡¨ç¤ºã§ããããã«ãªãã 使ç¨ãã¦ãããã¼ã¸ã§ã³ç®¡çã·ã¹ãã ã®åå(svn, git, hg, ...) ç¾å¨ã®ãã©ã³ãå ãã¼ã¸å¤±æã®ã¨ã©ã¼è¡¨ç¤º ããã« Git ã®å ´åã¯ä»¥ä¸
zshã®ã¿ã¼ããã«ã«ä»ãããã¹ã®ãªãã¸ããªã®æ å ±ã表示ãã¦ã¿ããã¨ã«ãã¾ããæçµç®æ¨ã¯ãããªæãã ãã©ã³ãåã表示 å ¨ã¦ã³ãããããã¦ããããªç¶æ ã§ããã°ç·è² addããã¦ããªããã¡ã¤ã«ãããã°+ãã¼ã¯ãã¤ãã¦èµ¤è² commitããã¦ããªããã¡ã¤ã«ãããã°!ãã¼ã¯ãã¤ãã¦é»è² ã¡ãªã¿ã«ãã®è¨äºã«æ¸ãã¦ãããã¨ã¯ zsh ã®ãã¼ã¸ã§ã³ã 4.3.10 以ä¸ã«éã£ã¦æå¹ã§ãã ãã¦ããããå®ç¾ããã«ã¯ vcs_info ã¨ãããã®ã使ãã¾ãã以ä¸ã®ãããªè¨è¿°ã ~/.zshrc ã«è¿½å ãã¾ãã # ãã®è¡ã¯ç¾å¨ã®ãã¹ã表示ããè¨å®ã§ãããã©ã³ãã表示ãã¦è²ãã¤ããè¨å®ã¨ã¯é¢ä¿ããã¾ãã RPROMPT="%{${fg[blue]}%}[%~]%{${reset_color}%}" autoload -Uz vcs_info setopt prompt_subst zstyle ':vcs_i
zshã¯æ¨æºã®æ©è½ã使ãã ãã§ã便å©ã ãã©ãããã§ã足ããªãã¨ãã¯ãããããªãã©ã°ã¤ã³ã追å ãã¦æ¡å¼µã§ãããã§ãããã©ã°ã¤ã³ä¸è¦§ã¯ã©ããã«ã¾ã¨ã¾ã£ã¦ããããã§ã¯ãªããç¹ã«ãzshæ¬ä½ã«æ¨æºã§å«ã¾ãã¦ãããã©ã°ã¤ã³ã¯man zshcontribãè¦ãã°ããããã©ããã以å¤ã®ã¦ã¼ã¶ãç¬èªã«ä½ã£ããã©ã°ã¤ã³ã¯Googleæ¤ç´¢ã¨ãã§å°éã«æ¢ããããªãã ããã§ãzshã§ä½¿ç¨ã§ããæ¨æºã§å«ã¾ãã¦ããªããã©ã°ã¤ã³ãã¾ã¨ãã¦ç´¹ä»ããããããåèã«ãã¦ãzshããã£ã¨ä¾¿å©ã«ãã¦ãã ãã! ãã£ã¬ã¯ããªç§»å åå æ¦è¦ åèè¨äº
# è£å®ãæå¹ã«ãã autoload -U compinit compinit -u # è£å®ã¡ãã»ã¼ã¸ãèªã¿ããããã zstyle ':completion:*' verbose yes zstyle ':completion:*' format '%B%d%b' zstyle ':completion:*:warnings' format 'No matches for: %d' zstyle ':completion:*' group-name '' è£å®é¢æ°ã®ã«ã¼ã« $fpath ã®éã£ããã£ã¬ã¯ããªã«è£å®é¢æ°ãç½®ã nyan ã³ãã³ãã®è£å®é¢æ°ãªã _nyan ã¨ããååã§ä¿åãã è£å®é¢æ°ã®å é ã«ã¯ #compdef nyan ã¨è£å®å¯¾è±¡ã®ã³ãã³ãåãæ¸ã ãã¡ã¤ã«åã¨åãååã®é¢æ°ãä½ããã®ä¸ã«è£å®é¢æ°ãæ¸ã ~/zsh/functions/_nyan
ä¼ç¤¾ã§ã³ã¼ããæ¸ãã¦ããã¨ãããããªããã¸ã§ã¯ãã®ãã£ã¬ã¯ããªéãé »ç¹ã«ç§»åãã¾ããæ¯åcdããã®ã¯ã ããã®ã§ãããã解æ¶ãã便å©ãªzshç¨ã®é¢æ°ã¨è£å®é¢æ°ãæ¸ããã®ã§ç´¹ä»ãã¾ããã¯ã¦ãªã®ã¨ã³ã¸ãã¢ã®ã²ã¨ã¨ãzshè£å®é¢æ°ãæ¸ãã¦ã¿ãã人ã«ã¯ããããå½¹ç«ã¤ã¨ãã£ã趣ã®ã¨ã³ããªã§ãã ä¼ç¤¾ã®ããã¸ã§ã¯ãã®ãªãã¸ããªã¯ã~/work/hatena ã¨ããã¨ããã«å ¨é¨ã¾ã¨ãã¦ãã¾ããã ããã以ä¸ã®ãããªæãã§ãã > ls ~/work/hatena Hatena-Antenna/ Hatena-Diary/ Hatena-Ugomemo/ git-hooks/ Hatena-Bookmark/ Hatena-Group/ Ridge/ iphone/ Hatena-Coco/ Hatena-Star/ android/ sketch/ åããã¸ã§ã¯ãã®ãªãã¸ããªã«ã¯é »ç¹ã«ç§»åããã®ã§ãç°¡åãªz
Homebrewã®å°å ¥æ¹æ³ã«ã¤ãã¦ã¯ä»¥åã®è¨äºãåèã«ãã¦ä¸ããã 以ä¸ãhomebrewããã³zshã¤ã³ã¹ãã¼ã«å¾ã«è¨å®ãã¦ããã¾ãã 1.zshæµã®ç°å¢å¤æ°PATHã®è¨å®æ¹æ³ ç°å¢å¤æ°PAHTã« "/usr/local/bin" ãªã©ã追å ããå ´åãzshã§ãbashã¨åãæ¹æ³ã§è¨å®ãããã¨ãã§ãã¾ãããä»åã¯zshæµã®è¨å®æ¹æ³ãè¡ãã¾ãããã 以ä¸ã®è¨å®ã "~/.zshrc" ã«è¿½å ãã¦ä¸ããã ## éè¤ãã¹ãç»é²ããªã typeset -U path cdpath fpath manpath ## sudoç¨ã®pathãè¨å® typeset -xT SUDO_PATH sudo_path typeset -U sudo_path sudo_path=({/usr/local,/usr,}/sbin(N-/)) ## pathãè¨å® path=(~/bin(N-/) /usr/l
12æ3æ¥éå½ã«æå³ä»¤ã宣è¨ããããããã¦å¯ç©ºã®å ã«å±ããããã³ã¼ãã¼ã 12æ3æ¥22æåããã ã©ããããããå°¹é«æ¦å¤§çµ±é ã«ããé常æå³ã宣è¨ããããããã«ã¤ãã¦ãéå½ã§çæ´»ãããç§ã®è¦ç·ã§è¨é²ããã¦ããããã¨æããä»é±ã¯æ¸ãããã ã£ãé«é&å°åæ è¡è¨ãã¹ã¿ã¼ãããããã£ãããå¾åãã«ããã ï¼åçã¯ä»åã®å¼¾å¾ãæ±ãããã¢ã§â¦
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}