OSX(mac)ã«Xmonadãã¤ã³ã¹ãã¼ã«ããæ¹æ³
æ®æ®µã¯Linuxã«Xmonadãå ¥ãã¦ä½æ¥ããã¦ãããï¼çæéã ãOSX(mac)ã使ããã¨ã¨ãªã£ã(ç¥ã£ã¦ããä¼æ¥ã大å¦ã£ã¦ãããã¨Let's Noteã¨Macbookã好ãï¼ThinkPadãé¸æè¢ã«å ¥ãã¦æ¬²ãã)ï¼æ®æ®µéãã«ä½æ¥ããããã«OSXã«Xmonadãå ¥ããæ¹æ³ã模索ãï¼åããã¨ããã¾ã§ã¯ãããï¼ãããLinuxã»ã©ã®å¿«é©ãã¯ãªãããï¼OSX(mac)ã§ã¯Xmonadã使ããªãã»ããè¯ãï¼ä»£ããã«Xmonadãæèãã¦ä½ãããAmethystãã¨ããããããããï¼ã¤ã³ã¹ãã¼ã«ã®æµããã¡ã¢ä»£ããã«æ¸ãæ®ãï¼
ç°å¢
$ uname -a å¾ã§å ¥åãã(確ãDarwinã®x64)
OSXã§Xmonadãåä½ãããä»çµã¿
Xmonadã¯X11ã§åä½ããããå®è£
ããã¦ããï¼ã©ããããä¾åãã¦ãããã¨ããã¨ï¼ã½ã¼ã¹ã³ã¼ãã®Mainé¨ã«ã¬ãããªX11é¢é£ã®é¢æ°ã使ã£ã¦ãã¦ç½®ãæãããã¨ãé¢åãããããªä½ä¾åãã¦ããï¼
ãã®ããOSXã§åä½ãããããã®ã¢ããã¼ãã¨ãã¦ã¯X11ã®OSXçã§ããXQuartzãã¤ã³ã¹ãã¼ã«ãï¼ãã®X11ä¸ã§åãããã¹ã¯ãããããã¼ã¸ã£(DM)ã«Xmonadãé¸æãï¼èµ·åãããæµãã¨ãªãï¼
ã¤ã³ã¹ãã¼ã«æ¹æ³
brewã®ã¤ã³ã¹ãã¼ã«
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
XQuartzã®ã¤ã³ã¹ãã¼ã«
https://www.xquartz.orgããXQuartz-2.7.9.dmg
ããã¦ã³ãã¼ãï¼ã¤ã³ã¹ãã¼ã«(ããã«ã¯ãªãã¯ã¨Continueãæ¼ãç¶ããã ã)ï¼
ã¤ã³ã¹ãã¼ã«ã«æåããã¨ï¼/Applications/Utilities/XQuartz.app
ã/opt/X11/bin/quartz-wm
ãªã©ãã§ãã¦ããã¯ãï¼ãã¹ã¯ãããã®æ¤ç´¢ãã¼ã¯ããXQuartzãæ¢ãï¼èµ·åããã¨Dock(ããã©ã«ãã ã¨ç»é¢ä¸ã«ããã·ã§ã¼ãã«ãããã¼ã並ãã§ããã¨ãã)ã«å¤§æåã®Xãä¸å¿ã®ãã¼ã¯ãç¾ããã¯ãï¼
XQuartzãé¸æããç¶æ
ã§ãã¹ã¯ãããã®å·¦ä¸ã®XQuartz -> Preferences
ã§å種è¨å®ãå¤æ´ããï¼Winodowã¿ãã§Full Screen Modeãè¨å®ãã以å¤ã¯ç¹ã«ããããªãã£ãï¼
~/.xinitrc
ãããã¨ã¨ã©ã¼ãåºããã¨ãããããï¼ãããªãrenameãã¦ããã»ããè¯ãï¼
Haskellãã¤ã³ã¹ãã¼ã«ãã
Xmonadãã¤ã³ã¹ãã¼ã«ããããã«Haskellã®ã³ã³ãã¤ã©ãªã©ãã¤ã³ã¹ãã¼ã«ããï¼She is Haskell.
ã£ã¦ç¬ããã¤ã¯è¡¨ã«åºãï¼ãããHæ¬ãæèªãã¦ããï¼
https://www.haskell.org/platform/mac.htmlããHaskellã®ã¤ã³ã¹ãã¼ã©ãè½ã¨ãï¼ããã«ã¯ãªãã¯ãã¦ã¤ã³ã¹ãã¼ã«ï¼
ã¤ã³ã¹ãã¼ã«ãçµãã£ããï¼ç«¯æ«ãã
$ cabal update
ã§ããã±ã¼ã¸ãªã¹ããææ°ã«æ´æ°ããï¼
xmonadã®ã¤ã³ã¹ãã¼ã«
ããããXmonadãã¤ã³ã¹ãã¼ã«ããï¼
$ cabal install xmonad
ã§ã§ããã¯ãã ãï¼ä»åã®ç°å¢ã§ã¯Xssã©ã¤ãã©ãªããªãã¨ã¨ã©ã¼ãåºãï¼åå ã¯å
ã»ã©ã¤ã³ã¹ãã¼ã«ããXQuartzãæã¤X11ã®ããããã©ã¤ãã©ãªé¢ä¿ããã¹ã«å«ã¾ãã¦ããªãã¨ã ã£ãï¼ãã£ã¦ä»åã®ã³ãã³ãã®ã¨ãã ããã¹ã追å ãã¦ããã°è¯ãï¼
$ LIBRARY_PATH=/opt/X11/lib:$LIBRARY_PATH cabal install xmonad
ããã§Xmonadãã¤ã³ã¹ãã¼ã«ã§ããã¯ãï¼ããã§ãé§ç®ãªãï¼
$ LIBRARY_PATH=/opt/X11/lib:$LIBRARY_PATh cabal install X11
ã試ãã¦ï¼ãããã°ãã¦ããï¼é å¼µãï¼
Xmonadé¢é£ã¤ã³ã¹ãã¼ã«
ã¨ã©ã¼ãåºãã®ãé²ãããã«X11é¢é£ã®ããããæ¤ç´¢ãã¹ã«å«ãã¦ããï¼ä»åã¯ã·ã³ããªãã¯ãªã³ã¯ãå¼µãæ¹æ³ãé¸ãã ï¼
$ ln -s /opt/X11/include/X11 /usr/local/include/X11 $ LIBRARY_PATH=/opt/X11/lib:$LIBRARY_PATH cabal install xmonad-contrib xmobar
XQuarzã®è¨å®ä½æ
X11(XQuartz)èµ·åæã«ä½¿ãããWMãè¨å®ããï¼è¨å®ã¯ç°å¢å¤æ°USERWM
ã«ä½¿ãããWMã®ãã¤ããªãã¹ãå
¥ãã¦ããï¼
$ mkdir $HOME/.xinitrc.d/ $ vim $HOME/.xinitrc.d/90-xmonad.sh #!/bin/sh USERWM=$HOME/Library/Haskell/bin/xmonad # xmonadã®ãã¤ããªãå ¥ã£ã¦ããã¨ãããæãããã«ãã
xmonadã®ãã¹ãããããªãã¨ãã¯
$ find $HOME -name xmonad -type f 2>/dev/null
ã§æ¤ç´¢ããï¼
ãã¨ã¯X11ãèµ·åæã«å®è¡ãããããã«ã¹ã¯ãªããã«å®è¡æ¨©éãä»ä¸ããï¼
$ chmod +x ~/.xinitrc.d/90-xmonad.sh
X11ã§èµ·åããWMãããã©ã«ãã®quartz-wm
ã«æ»ããããã°
$ chmod -x ~/.xinitrc.d/90-xmonad.sh
ã§å®è¡æ¨©éããªããã°è¯ãï¼
以ä¸ã§åºæ¬çãªä½æ¥ã¯çµäºï¼
å¾ã¯åèªxmonad.hs
ã.xmobarrc
ãªã©ã調æ´ããï¼
èµ·å
XQuartzãèµ·åããç¶æ
ã§å·¦ä¸ã®XQuartzã¿ããæ¼ãã¦ï¼Toggle Full Screen
ãæ¼ãï¼å
¨ç»é¢ãX11ã«ãªãï¼Xmonadã使ããããã«ãªã(å
¨ç»é¢ã«ããªãã¦ã使ãããï¼å
¨ç»é¢ã®ã»ãããããã)ï¼
æ»ãæ¹
Command+Option+a
åé¡ç¹
ã¯ã¼ã¯ã¹ãã¼ã¹ã®åãæ¿ãï¼è¤æ°ã®ç«¯æ«æä½ã¯é常éãè¡ãããï¼/Applications
以ä¸ã®ã¢ããª(ãã©ã¦ã¶ãã¡ã¼ã©)ãXmonadä¸ã§å®è¡ããæ¹æ³ãããããªãã¨ãã£ãè´å½çãªåé¡ã«ã¶ã¡å½ããï¼è§£æ±ºçãæãã¤ããªãã£ãï¼å°ã使ã£ã¦ã¿ã¦ã®åé¡ã¨ãã¦ã¯ä»¥ä¸ãæããããï¼
- OSXã§ã¯Xmonadã®ç¸æ£
urxvt
ã§clear
ã³ãã³ããåããªã - Chromeãªã©ã®
/Applications
以ä¸ã«ã¤ã³ã¹ãã¼ã«ããã¦ããã¢ããªãèµ·åãããã¨Xmonadãããã¹ãã®WMã«æ»ãï¼ãã¡ãã§èµ·åãã¦ãã¾ã - ããã©ã«ãã§èµ·åããxtermã¯ãã«ããã¤ãæåèªããªãã»å ¥åã§ããªã
xmonad.hs
ï¼.xmobarrc
ãOSXç¨ã«èª¿æ´ããªãã¨ãããªã- ãããã°ããããªã
åé¡ãå±±ç©ã¿ã§ããã¾ã§ãã¦Xmonadã«åºå·ããå¿
è¦ããªãæ°ããã¦ããããï¼Amethyst
ã試ãã¦ã¿ãï¼ããããæ¯è¼çå¿«é©ã ã£ãããä»åã¯ãã£ã¡ã使ããã¨ã«ããï¼
Amethystã®ã¤ã³ã¹ãã¼ã«
$ brew cask install amethyst
ã¨ã¦ãç°¡åï¼
Amethystè¨å®
System Preferences
ãç«ã¡ä¸ãï¼Security & Privacy -> Accessibility
ï¼å·¦ä¸ã®ããã¯ãã¿ã³ãæ¼ãã¦ããã¯ã解é¤ãï¼'+'ãæ¼ãï¼Applications -> Amethyst
ãé¸æãï¼æ¨©éãä¸ããï¼è©³ããã¯Amethystã®githubãè¦ãã®ãããããããï¼
Amethystã®èµ·å
ãã¹ã¯ãããã®æ¤ç´¢ããAmethystãæ¤ç´¢ãã¦èµ·åããã ãï¼
æä¾ããæ©è½ã¯ã¦ã£ã³ãã¦å士ã®é
ç½®ãèªåã§Xmonad風ã«æ´å½¢ï¼ã¦ã£ã³ãã¦ã®é¸æã»å
¥ãæ¿ãã¨ãã£ãã·ã³ãã«ãªé¨åã®ã¿ï¼
ã¯ã¼ã¯ã¹ãã¼ã¹ã®åãæ¿ãã¯Mission Controlã«ãããã®ã«ãªããï¼ã©ãã«ãç¡é§ãªåä½ãå¤ãã¦ç²ããï¼xmobarãå
¥ãã¦ä½¿ããããï¼ããã£ã½ããã®ã¯ä»ã®æç¡ãããã ï¼OSXã¯ä½ç¨è¿½ãè©°ããããªãéã使ããªãã¨æ±ºå¿ããï¼
ä»ã«ã¯https://github.com/arnihermann/osxmonadã¨ãã£ããã®ãããããã ã£ããï¼ã¯ã¼ã¯ã¹ãã¼ã¹ã®å®è£
ãããã¦ããªãã¨æ¸ãã¦ãã£ããã使ããªãã£ãï¼
æå¾ã«
Linuxã¯ããããã
åèãµã¤ã
Xmonad on Apple OSX: Xmonad/Using xmonad on Apple OSX - HaskellWiki
xmonad Q&A: Can't build X11 due to ld linking error on OSX 10.9.2 · Issue #24 · xmonad/X11 · GitHub
彼女ã¯ã¡ãã£ã¨ç´æ ãããã ããªãã : She is Haskell. : プログラマーが覚えておくべき10の英語フレーズ - NAVER まとめ
Amethyst: GitHub - ianyh/Amethyst: Automatic tiling window manager for OS X à la xmonad and i3.