究極ãããããæå"z"ãå ããzshããã®ã·ã§ã«ã®åãåãã¦ãã¨ã³ã¸ãã¢ã®æ¥ã ã®ä½æ¥ãä½å¦ã¾ã§å¹çåã§ãããã究極ã®ã·ã§ã«ã®æå¼·ã®è¨å®ãæ¢ãã¾ãã
究極ãããããæå"z"ãå ããzshããã®ã·ã§ã«ã®åãåãã¦ãã¨ã³ã¸ãã¢ã®æ¥ã ã®ä½æ¥ãä½å¦ã¾ã§å¹çåã§ãããã究極ã®ã·ã§ã«ã®æå¼·ã®è¨å®ãæ¢ãã¾ãã
ãã®è¨äºã¯ã2013å¹´12æ20æ¥ã«æ¸ãã¾ããã ã»2014å¹´5æ15æ¥ã«zshã®è¨å®ã«preztoã®äºãååã ãç´¹ä»ãã¾ããã ã»2014å¹´5æ15æ¥ã«.zshrcèªã¿è¾¼ããã³ã«PATHãå¢ãã¦ããå ´åã®å¯¾å¦æ³ã追å ãã¾ããã â ã¾ããã èªåãªãã®zshãå ¥ããã¡ãªããã å ¥åè£å®ãåªãã¦ã âï¾+。ï¾(ï½¥âï½¥)ï¾ï½¡+ï¾ï½²ï½²!! éæ¨æºã³ãã³ã(brewãgitã¨ã)ã®å ¥åè£å® âï¾+。ï¾(ï½¥âï½¥)ï¾ï½¡+ï¾ï½²ï½²!! ã«ã©ã¼ãªã³ã°ãbashããè¦ããã âï¾+。ï¾(ï½¥âï½¥)ï¾ï½¡+ï¾ï½²ï½²!! bashããå¦çãé«é åæã«ç«ã¡ä¸ãã¦ãã¿ã¼ããã«éã§ã®historyå ±æ æéã®ãããå¦çãçµãã£ããéç¥ gitã®ã«ã¬ã³ããã©ã³ãã®è¡¨ç¤º âï¾+。ï¾(ï½¥âï½¥)ï¾ï½¡+ï¾ï½²ï½²!! å±¥æ´æ©è½ãå¼·å(æ¹è¡ãè¨é²ããã) âï¾+。ï¾(ï½¥âï½¥)ï¾ï½¡+ï¾ï½²ï½²!! 2014å¹´1æå·ã®ã½ããã¦ã§ã¢ãã¶ã¤ã³èªã«ã·ã§
ã¯ããã« ãã®ã¬ã¤ãã§ã¯ãã¯ãã㦠Zsh ã使ã人ã Zsh ã®ä¾¿å©ãªä½¿ãæ¹ãç¥ããªã人ã«åãã¦ãããã¤ãã®ä¾¿å©ãªè¨å®ã¨æä½æ¹æ³ãç´¹ä»ãã¾ããã¾ãã Zsh ã«ã¤ãã¦ã®çåãç´ æ©ã解決ã§ãããããããã¥ã¢ã«ã®èª¿ã¹æ¹ãä»ã®ããã¥ã¡ã³ãã¸ã®ãªã³ã¯ãçãè¾¼ãã§ããã¾ãã ãã®ã¬ã¤ãã§ã«ãã¼ãããã¦ããªãè¨å®ãåãããããããã¥ã¡ã³ãããåç¥ã§ãããããã²ç·¨éãªã¯ã¨ã¹ããã³ã¡ã³ãã§ãç¥ãããã ããã è¨å®ãã¡ã¤ã« ããã§ã¯ä¸»ã«æ®æ®µã®ãã¼å ¥åæ°ãå¤§å¹ ã«æ¸ããããããªè¨å®ãç´¹ä»ãã¾ãã .zshrc ~/.zshrc 㯠Zsh ã®ã¤ã³ã¿ã©ã¯ãã£ãã·ã§ã«ï¼ã¦ã¼ã¶ã¼ãã³ãã³ããå ¥åããç»é¢ï¼ãèµ·åããéã«èªã¿è¾¼ã¾ããè¨å®ãã¡ã¤ã«ã§ãã Zsh ã¹ã¯ãªãããå®è¡ãããã zsh -c 'command...' ã§ã³ãã³ããå®è¡ãããããã¨ãã«ã¯èªã¿è¾¼ã¾ãã¾ããããã®ãã¡ã¤ã«ã«ã¯ä¸»ã« Zsh ã®æä½ã«é¢ã
2011å¹´01æ29æ¥(å) ã«å¤§éªã§ Minami.rb 第ï¼ååå¼·ä¼ ãéããã(åç¥ãã¼ã¸)ãRuby on Rails(Ruby)ã¡ã¤ã³ã®åå¼·ä¼ã ã ããã§15åæ ã®çºè¡¨ã³ã¼ãã¼ããã£ãã®ã§ zsh ã®çºè¡¨ããã¦ãããzsh ã£ã¦é«æ©è½ãªãã ãã©ãå®ã¯ã·ã§ã«ã«è©³ãããªã人ã§ã便å©ã«ä½¿ããããªã®ã§ããªããèå³ãããã©é£ãããã£ã¦æã£ã¦ã人ã¯åèã«ãã¦æ¬²ããã çºè¡¨è³æ çºè¡¨è³æã¯ãããªæããããèªä½ã¯ããã¾ãèªã¾ãªãã¦ããããã©ãä¸å¿è²¼ãä»ãã¦ããã 15åã§ããã zshView more presentations from mollifier . ããã«å®éã®ã³ãã³ãã©ã¤ã³æä½ãè¦ããªãã説æãããçºè¡¨å 容ã¯ä»¥ä¸ã è£å® zsh ã¯ãªãã¨è¨ã£ã¦ãè£å®ã便å©ãã¨ã«ããããã ~/.zshrc ã«æ¸ãã¦ãããã autoload -Uz compinit compinit ããã§ã
Qiita è¦ã¦ãããããªæ稿ãè¦ã¤ããã Zsh - ããä½æ¥ããDirãBookmarkããshellã¹ã¯ãªãã - Qiita ã ãããããã使ããã£ã¬ã¯ããªã« cd ãããã¨ã cd ~/work/project/ruby/web ã¨ãé·ãååãæã¤ã®ã¯ããã©ãããã$CDPATH ãéãã¦ããã£ã¦ããæããããã©ãã¿ãã§è£å®ããã¨ãã«åè£ããã£ã±ãåºãããã¦å¾®å¦ã«ä¾¿å©ãããªãããããªã¨ãã«ããã使ãã°ãã£ã¬ã¯ããªã®ç§»åãç°¡åã«ãªãã ã¡ãã£ã¨æ¹è¯ã®ä½å°ãããã¨ããããã¿ãã§è£å®ã§ããããã«ããããã£ã¨ä¾¿å©ã«ãªãã¨æã£ã¦ãç¬ç«ãã zsh ã®ãã©ã°ã¤ã³ã¨ãã¦æ¸ãç´ããã®ã§ç´¹ä»ããã ãã®ãã©ã°ã¤ã³ã§ã§ããã㨠cd-bookmark ã¨ãããã©ã°ã¤ã³ãä½ã£ãããããã¤ã³ã¹ãã¼ã«ããã° cd-bookmark ã¨ããã³ãã³ãã使ããããã«ãªãã ããã¤ã使ãã°ãã使ããã£ã¬ã¯ããªã«å¥
俺èã4ã¨ããã¤ãã³ã㧠zsh ã«ã¤ãã¦çºè¡¨ãã¾ãã (ãã®æã®çºè¡¨è³æ)ããæ®æ®µã·ã§ã«ã使ã£ã¦ããªã人ã§ã zsh ã使ãã¨ä¾¿å©ã ããã¨ããå 容ã§çºè¡¨ããã®ã§ããããèãã¦ä½¿ã£ã¦ã¿ããã¨æã£ã人ãããããã§ãã ã§ãã°ã°ã£ã¦ã¿ã¦ãè²ã åãã£ã¦ã人åãã®è¨äºã¯ããã¾ããããã©ããã£ã¦èµ·åãããã§ãã?ãã¨ããæ¬å½ã®åå¿è ã®ããã®è¨äºã¯ããã¾ãããã¾ããã ããããåãã¦ã®äººã«ã zsh ã使ã£ã¦æ¬²ããã¨æã£ãã®ã§ãåå¿è åãã®å ¥éè¨äºãæ¸ãã¾ãããMac ã使ãã°ç°¡åã« zsh ãå§ãããã®ã§ã使ãæ¹ãåãããªãã¨ãã人ã¯åèã«ãã¦ã¿ã¦ãã ããã ã¿ã¼ããã«ãèµ·åãã zsh ã¯ãã¿ã¼ããã«ãã¨ããã¢ããªãèµ·åãã¦ä½¿ãã¾ãã ãã¢ããªã±ã¼ã·ã§ã³ã -> ãã¦ã¼ãã£ãªãã£ãã®ä¸ã«ãã¿ã¼ããã«ããããã®ã§èµ·åãã¦ã¿ã¾ãããã 次åèµ·åããã¨ãã®ããã« Doc ã«è¿½å ãã¦ããã¨ä¾¿å©ã§ãã zs
â» 2013/8/30 TravisClèªåãã¹ãæ©è½è¿½å ã®ãããinstallã®è¨è¿°ãä¸é¨ä¿®æ£ãã¾ããã ãããªè¨³ã§ãClipssã¨è¨ããã¼ã«ãä½ã£ã¦ã¿ã¾ããã®ã§ç´¹ä»ã§ãã GitHub Clipss Clipss ã¨ã¯ ããã¹ãã®ã³ããå ±æããããã®ãã¼ã«ã§ãã zsh tmux Emacs vim ã§ã¯yank killãªã©ã«ããã¯ãã¦ã¾ãã Emacsãªã©tmuxã§è¤æ°ç»é¢ãå¤éããã»ã¹èµ·åãã¦ãã¦ããbufferå ±æãã¾ãã MacOSX windowsãªã©ã§ã¯ã¯ãªãããã¼ããç£è¦ãã¦ã¾ãã è¤æ°PCéã§ãå ±æOKã§ãã Ruby使ã£ã¦ä¸é¨ã®åæé¨åãåããã¦ã¾ãã è¤æ°PCéã¯httpã§éä¿¡ãã¦ã¾ãã ä¾ããããªä½¿ãæ¹ãã§ãã¾ãã Emacsã®ç»é¢ã§ã hello worldã¨å ¥å. è¡é ã«ç§»åã㦠C-k (kill-line)ã¨ããã å¥ PC (windows)ã«ç§»åãã¦
ä¼ç¤¾ã§ã³ã¼ããæ¸ãã¦ããã¨ãããããªããã¸ã§ã¯ãã®ãã£ã¬ã¯ããªéãé »ç¹ã«ç§»åãã¾ããæ¯å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
hoge[tab]ã§ãµãã³ãã³ããè£å®ããã ãµãã³ãã³ãã®å¾ã¯ãã¡ã¤ã«ããã£ã¬ã¯ããªãè£å®ãããããã«ã ãµãã³ãã³ãã¨ãã¡ã¤ã«åãè£å®ãã ä¸è¨ã.zshrcã«è¨è¼ãã¦exec $SHELL ãã£ã¦ãããã¨ã¯ compdefã§_hogecmdã¨ããè£å®ç¨functionãå®ç¾©ããhogeã³ãã³ããå®è¡ããã¨ãã«å¼ã³åºãããããã«ã functionå ã®cmdsã§è£å®ããããµãã³ãã³ããåæ CURRENT == 2ã§hogeã®ãã¨ã«è£å®ãããã®ã¯ãµãã³ãã³ãã ãã¨æå® _describeã§è£å®åè£ã§è¡¨ç¤ºãããã¨ãã«subcommandã¨ããã°ã«ã¼ãã«ãªãããã«ãã¦ãã ãµãã³ãã³ãã®ãã¨ã¯_filesã§ãã¡ã¤ã«ã¨ãã£ã¬ã¯ããªãè£å®ãããããã« åèã«ãªããµã¤ã zshã®è£å®é¢æ°ã®æ¸ãæ¹ãã¾ã¨ã¾ã£ã¦ããã¨ãããã»ã¨ãã©ç¡ãã®ã§ä¸è¨ãé常åèã«ãªãã¾ãã zshè£å®é¢æ°ãèªä½ããã¨ä¾¿å© -
æ¦è¦ Emacs ãå©ç¨ãã¦ããã¨å ¨é¨ Emacs ã§ãããããªãã®ã¯ Emacs 使ãã¨ãã¦å½ç¶ã ã¨æãã¾ãã Shell ã ã£ã¦ Terminal ãªã©å©ç¨ãã Emacs ä¸ã§åä½ãããããªããã¨ã§ãããã ãã®ææ¸ã§ã¯ Emacs ä¸ã§ Shell ãå¿«é©ã«å©ç¨ããããã®è¨å®ãè¨è¿°ãã¦ããã¾ãã ç®æ¬¡ æ¦è¦ æ¤è¨¼ç°å¢ Emacs ã§ã® Shell Mode ã«é¢ããåºç¤ç¥è shell term (ansi-term) eshell ã©ã®ã¢ã¼ããå©ç¨ããã å©ç¨ãã Shell ã«ã¤ã㦠Windows ã§ã® Shell ã®æºå Mac OS X ã§ã® Shell ã®æºå Emacs å´ã®è¨å® PATH ã®è¨å® å©ç¨ãã Shell ã®è¨å® æåã³ã¼ãã®è¨å® ã·ã¹ãã ã® terminfo ãå©ç¨ããªãè¨å® ã¨ã¹ã±ã¼ãã綺éºã«è¡¨ç¤ºãã term å¼ã³åºããã¼ã®å²ãå½ã¦ Shell å´
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}