Created
October 20, 2011 00:38
-
-
Save kofno/1300108 to your computer and use it in GitHub Desktop.
XMonad on Unity 2D (Ubuntu 11.10); Based on http://www.haskell.org/haskellwiki/Xmonad/Using_xmonad_in_Unity_2D
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# in /usr/share/xsessions | |
[Desktop Entry] | |
Name=Xmonad GNOME | |
Comment=Tiling window manager | |
TryExec=/usr/bin/gnome-session | |
Exec=gnome-session --session=xmonad | |
Type=XSession |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# in /usr/share/applications | |
[Desktop Entry] | |
Type=Application | |
Encoding=UTF-8 | |
Name=Xmonad | |
Exec=xmonad | |
NoDisplay=true | |
X-GNOME-WMName=Xmonad | |
X-GNOME-Autostart-Phase=WindowManager | |
X-GNOME-Provides=windowmanager | |
X-GNOME-Autostart-Notify=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- in ~/.xmonad | |
import XMonad | |
import XMonad.Config.Gnome | |
import XMonad.Hooks.ManageDocks | |
import XMonad.Util.EZConfig | |
import XMonad.Layout.Gaps | |
import Data.List | |
myManageHook = composeAll . concat $ | |
[ [ className =? "Firefox-bin" --> doShift "6:ff" ] | |
, [ className =? "Firefox" --> doShift "6:ff" ] | |
, [(className =? "Firefox" <&&> resource =? "Dialog") --> doFloat] | |
, [ className =? "Emacs" --> doShift "2:emacs" ] | |
, [ className =? "Emacsclient" --> doShift "2:emacs" ] | |
, [ className =? "Unity-2d-panel" --> doIgnore ] | |
, [ className =? "Unity-2d-launcher" --> doIgnore ] | |
] | |
myLayouts = gaps [(U, 24)] $ layoutHook gnomeConfig | |
main = xmonad $ gnomeConfig | |
{ workspaces = ["1:chrome","2:emacs","3:console","4:server","5:mail","6:ff","7","8","9","0","-","="] | |
, manageHook = myManageHook <+> manageHook gnomeConfig | |
, modMask = mod4Mask | |
, layoutHook = myLayouts | |
, terminal = "urxvt" | |
, focusFollowsMouse = False | |
} | |
`additionalKeysP` [ ("M-S-q", spawn "gnome-session-quit --power-off") ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# in /usr/share/gnome-session/sessions | |
[GNOME Session] | |
Name=Xmonad Unity-2D Desktop | |
RequiredComponents=gnome-settings-daemon; | |
RequiredProviders=windowmanager;panel; | |
DefaultProvider-windowmanager=xmonad | |
DefaultProvider-panel=unity-2d-panel |
@onurgu for unity-2d-panel you can give doFloat instead of doIgnore
@kofno How is xmonad.session used?
i would read comments too 👀
Wow, too much noise in my github feed I guess @gokulnath
@trygvis that is the session configuration that is fed to gnome-session when it starts and tells it what services to use.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
I'll have a question even if I didn't try your configuration yet. However, I tried another recipe and went on to adapt my existing configuration.
What I would like to do is to have only unity-2d-panel and not unity-2d-launcher. Yet I also want the menubars (i.e. Firefox's menus, or any other ordinary gnome application's) to appear in unity-2d-panel. But it doesn't work as I like right away if I just comment out unity-2d-launcher from relevant files.
Could the reason be me not executing unity-2d-launcher?
Can you give me a pointer about the connection between the menubars in the panel and the applications?
Thank you in advance.