From d1a4e4a6d60f97c22d1d1463eb2898c20e6db05c Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Sat, 25 Nov 2017 21:01:49 +0100 Subject: Move old files to stow-correct positions --- minttyrc/.minttyrc | 33 +++++++++++++++++ minttyrc/minttyrc | 33 ----------------- xbindkeys/.xbindkeysrc.scm | 57 ++++++++++++++++++++++++++++ xbindkeys/xbindkeysrc.scm | 57 ---------------------------- xmonad/.xmonad/xmonad.hs | 92 ++++++++++++++++++++++++++++++++++++++++++++++ xmonad/xmonad/xmonad.hs | 92 ---------------------------------------------- 6 files changed, 182 insertions(+), 182 deletions(-) create mode 100644 minttyrc/.minttyrc delete mode 100644 minttyrc/minttyrc create mode 100644 xbindkeys/.xbindkeysrc.scm delete mode 100644 xbindkeys/xbindkeysrc.scm create mode 100644 xmonad/.xmonad/xmonad.hs delete mode 100644 xmonad/xmonad/xmonad.hs diff --git a/minttyrc/.minttyrc b/minttyrc/.minttyrc new file mode 100644 index 0000000..2e7f2d8 --- /dev/null +++ b/minttyrc/.minttyrc @@ -0,0 +1,33 @@ +BoldAsFont=no +Font=Cousine +FontHeight=12 +FontSmoothing=default +Locale=en_GB +Charset=UTF-8 +Columns=100 +Rows=36 +Scrollbar=none +Transparency=off +OpaqueWhenFocused=no +CursorType=block +CursorBlinks=no +RightClickAction=extend +BoldBlack=0,43,54 +Black=7,54,66 +BoldGreen=88,110,117 +BoldYellow=101,123,131 +BoldBlue=131,148,150 +BoldCyan=147,161,161 +White=238,232,213 +BoldWhite=253,246,227 +Yellow=181,137,0 +BoldRed=203,75,22 +Red=220,50,47 +Magenta=211,54,130 +BoldMagenta=108,113,196 +Blue=38,139,210 +Cyan=42,161,152 +Green=133,153,0 +ForegroundColour=101,123,117 +BackgroundColour=253,246,227 +CursorColour=112,129,131 diff --git a/minttyrc/minttyrc b/minttyrc/minttyrc deleted file mode 100644 index 2e7f2d8..0000000 --- a/minttyrc/minttyrc +++ /dev/null @@ -1,33 +0,0 @@ -BoldAsFont=no -Font=Cousine -FontHeight=12 -FontSmoothing=default -Locale=en_GB -Charset=UTF-8 -Columns=100 -Rows=36 -Scrollbar=none -Transparency=off -OpaqueWhenFocused=no -CursorType=block -CursorBlinks=no -RightClickAction=extend -BoldBlack=0,43,54 -Black=7,54,66 -BoldGreen=88,110,117 -BoldYellow=101,123,131 -BoldBlue=131,148,150 -BoldCyan=147,161,161 -White=238,232,213 -BoldWhite=253,246,227 -Yellow=181,137,0 -BoldRed=203,75,22 -Red=220,50,47 -Magenta=211,54,130 -BoldMagenta=108,113,196 -Blue=38,139,210 -Cyan=42,161,152 -Green=133,153,0 -ForegroundColour=101,123,117 -BackgroundColour=253,246,227 -CursorColour=112,129,131 diff --git a/xbindkeys/.xbindkeysrc.scm b/xbindkeys/.xbindkeysrc.scm new file mode 100644 index 0000000..7b00c38 --- /dev/null +++ b/xbindkeys/.xbindkeysrc.scm @@ -0,0 +1,57 @@ +;; To specify a key, you can use 'xbindkeys --key' or +;; 'xbindkeys --multikey' and put one of the two lines in this file. + +;; A list of keys is in /usr/include/X11/keysym.h and in +;; /usr/include/X11/keysymdef.h +;; The XK_ is not needed. + +;; List of modifier: +;; Release, Control, Shift, Mod1 (Alt), Mod2 (NumLock), +;; Mod3 (CapsLock), Mod4, Mod5 (Scroll). + + +;; The release modifier is not a standard X modifier, but you can +;; use it if you want to catch release instead of press events + +;; By defaults, xbindkeys does not pay attention to modifiers +;; NumLock, CapsLock and ScrollLock. +;; Uncomment the lines below if you want to use them. +;; To dissable them, call the functions with #f + + +;;;;EXTRA FUNCTIONS: Enable numlock, scrolllock or capslock usage +;;(set-numlock! #t) +;;(set-scrolllock! #t) +;;(set-capslock! #t) + +;;;;; Scheme API reference +;;;; +;; Optional modifier state: +;; (set-numlock! #f or #t) +;; (set-scrolllock! #f or #t) +;; (set-capslock! #f or #t) +;; +;; Shell command key: +;; (xbindkey key "foo-bar-command [args]") +;; (xbindkey '(modifier* key) "foo-bar-command [args]") +;; +;; Scheme function key: +;; (xbindkey-function key function-name-or-lambda-function) +;; (xbindkey-function '(modifier* key) function-name-or-lambda-function) +;; +;; Other functions: +;; (remove-xbindkey key) +;; (run-command "foo-bar-command [args]") +;; (grab-all-keys) +;; (ungrab-all-keys) +;; (remove-all-keys) +;; (debug) + +(xbindkey '(mod4 F9) "mpc toggle") +(xbindkey '(mod4 F10) "mpc prev") +(xbindkey '(mod4 F11) "mpc next") +(xbindkey '(mod4 F12) "mpc stop") + +(xbindkey '(mod4 p) "dmenu_run -fn '-misc-termsyn-medium-r-normal--11-79-100-100-c-60-*-*' -nb '#002b36' -nf '#fdf6e3' -sb '#586e75' -sf '#fdf6e3' -hist '/home/alan/.cache/dmenu_run_history'") +(xbindkey '(mod4 shift T) "urxvtc") +(xbindkey '(mod4 shift E) "emacsclient -c") diff --git a/xbindkeys/xbindkeysrc.scm b/xbindkeys/xbindkeysrc.scm deleted file mode 100644 index 7b00c38..0000000 --- a/xbindkeys/xbindkeysrc.scm +++ /dev/null @@ -1,57 +0,0 @@ -;; To specify a key, you can use 'xbindkeys --key' or -;; 'xbindkeys --multikey' and put one of the two lines in this file. - -;; A list of keys is in /usr/include/X11/keysym.h and in -;; /usr/include/X11/keysymdef.h -;; The XK_ is not needed. - -;; List of modifier: -;; Release, Control, Shift, Mod1 (Alt), Mod2 (NumLock), -;; Mod3 (CapsLock), Mod4, Mod5 (Scroll). - - -;; The release modifier is not a standard X modifier, but you can -;; use it if you want to catch release instead of press events - -;; By defaults, xbindkeys does not pay attention to modifiers -;; NumLock, CapsLock and ScrollLock. -;; Uncomment the lines below if you want to use them. -;; To dissable them, call the functions with #f - - -;;;;EXTRA FUNCTIONS: Enable numlock, scrolllock or capslock usage -;;(set-numlock! #t) -;;(set-scrolllock! #t) -;;(set-capslock! #t) - -;;;;; Scheme API reference -;;;; -;; Optional modifier state: -;; (set-numlock! #f or #t) -;; (set-scrolllock! #f or #t) -;; (set-capslock! #f or #t) -;; -;; Shell command key: -;; (xbindkey key "foo-bar-command [args]") -;; (xbindkey '(modifier* key) "foo-bar-command [args]") -;; -;; Scheme function key: -;; (xbindkey-function key function-name-or-lambda-function) -;; (xbindkey-function '(modifier* key) function-name-or-lambda-function) -;; -;; Other functions: -;; (remove-xbindkey key) -;; (run-command "foo-bar-command [args]") -;; (grab-all-keys) -;; (ungrab-all-keys) -;; (remove-all-keys) -;; (debug) - -(xbindkey '(mod4 F9) "mpc toggle") -(xbindkey '(mod4 F10) "mpc prev") -(xbindkey '(mod4 F11) "mpc next") -(xbindkey '(mod4 F12) "mpc stop") - -(xbindkey '(mod4 p) "dmenu_run -fn '-misc-termsyn-medium-r-normal--11-79-100-100-c-60-*-*' -nb '#002b36' -nf '#fdf6e3' -sb '#586e75' -sf '#fdf6e3' -hist '/home/alan/.cache/dmenu_run_history'") -(xbindkey '(mod4 shift T) "urxvtc") -(xbindkey '(mod4 shift E) "emacsclient -c") diff --git a/xmonad/.xmonad/xmonad.hs b/xmonad/.xmonad/xmonad.hs new file mode 100644 index 0000000..21e197d --- /dev/null +++ b/xmonad/.xmonad/xmonad.hs @@ -0,0 +1,92 @@ +import XMonad +import qualified XMonad.StackSet as W +import XMonad.Hooks.DynamicLog +import XMonad.Hooks.EwmhDesktops +import XMonad.Hooks.ManageDocks +import XMonad.Hooks.ManageHelpers +import XMonad.Layout.NoBorders +import XMonad.Layout.WindowNavigation +import XMonad.Util.EZConfig +import XMonad.Util.Run(spawnPipe) +import System.Exit +import System.IO +import Data.List(isPrefixOf) + +myManageHook :: ManageHook +myManageHook = composeOne + [ className =? "Firefox" -?> doShift "2" + , className =? "Pidgin" -?> doShift "3" + , className =? "nuvolaplayer" -?> doShift "8" + , className =? "Transmission-gtk" -?> doShift "9" + , isFullscreen -?> doFullFloat + , fmap ("mpv" `isPrefixOf`) title -?> doFullFloat + ] + +myKeys c = mkKeymap c $ + [ ("M-S-", spawn $ XMonad.terminal c) + , ("M-k", kill) + + , ("M-", spawn "exec $(dmenu_path | dmenu)") + , ("M-x M-e", spawn "emacsclient -c") + + , ("M-t", withFocused $ windows . W.sink) + , ("M-m", windows W.focusMaster) + , ("M-S-m", windows W.swapMaster) + + , ("M-", sendMessage $ Go R) + , ("M-", sendMessage $ Go L) + , ("M-", sendMessage $ Go U) + , ("M-", sendMessage $ Go D) + , ("M-M1-", sendMessage $ Swap R) + , ("M-M1-", sendMessage $ Swap L) + , ("M-M1-", sendMessage $ Swap U) + , ("M-M1-", sendMessage $ Swap D) + , ("M-C-", sendMessage $ Move R) + , ("M-C-", sendMessage $ Move L) + , ("M-C-", sendMessage $ Move U) + , ("M-C-", sendMessage $ Move D) + + , ("M-n", windows W.focusDown) + , ("M-p", windows W.focusUp) + , ("M-S-n", windows W.swapDown) + , ("M-S-p", windows W.swapUp) + + , ("M-,", sendMessage (IncMasterN 1)) + , ("M-.", sendMessage (IncMasterN (-1))) + + , ("M-\\", sendMessage NextLayout) + , ("M-S-\\", setLayout $ XMonad.layoutHook c) + + , ("M-+", sendMessage Shrink) + , ("M--", sendMessage Expand) + + , ("M-q", broadcastMessage ReleaseResources + >> restart "xmonad" True) + , ("C-M-q", io (exitWith ExitSuccess)) + ] ++ + + -- mod-[1..9], Switch to workspace N + -- mod-shift-[1..9], Move client to workspace N + [(m ++ k, windows $ f w) + | (w, k) <- zip (XMonad.workspaces c) (map show [1..9]) + , (m, f) <- [("M-",W.greedyView), ("M-S-",W.shift)]] + + +main :: IO () +main = do + xmproc <-spawnPipe "/usr/bin/xmobar /home/alan/.xmobarrc" + xmonad $ defaultConfig + { manageHook = myManageHook <+> manageDocks <+> manageHook defaultConfig + , layoutHook = smartBorders . avoidStruts $ layoutHook defaultConfig + , logHook = dynamicLogWithPP xmobarPP + { ppOutput = hPutStrLn xmproc + , ppTitle = xmobarColor "#859900" "" . shorten 200 + , ppCurrent = xmobarColor "#b58900" "". wrap "[" "]" + , ppHiddenNoWindows = xmobarColor "#93a1a1" "" + , ppUrgent = xmobarColor "#dc322f" "#b58900" + } + , terminal = "urxvt" + , modMask = mod4Mask + , handleEventHook = fullscreenEventHook + , keys = myKeys + } diff --git a/xmonad/xmonad/xmonad.hs b/xmonad/xmonad/xmonad.hs deleted file mode 100644 index 21e197d..0000000 --- a/xmonad/xmonad/xmonad.hs +++ /dev/null @@ -1,92 +0,0 @@ -import XMonad -import qualified XMonad.StackSet as W -import XMonad.Hooks.DynamicLog -import XMonad.Hooks.EwmhDesktops -import XMonad.Hooks.ManageDocks -import XMonad.Hooks.ManageHelpers -import XMonad.Layout.NoBorders -import XMonad.Layout.WindowNavigation -import XMonad.Util.EZConfig -import XMonad.Util.Run(spawnPipe) -import System.Exit -import System.IO -import Data.List(isPrefixOf) - -myManageHook :: ManageHook -myManageHook = composeOne - [ className =? "Firefox" -?> doShift "2" - , className =? "Pidgin" -?> doShift "3" - , className =? "nuvolaplayer" -?> doShift "8" - , className =? "Transmission-gtk" -?> doShift "9" - , isFullscreen -?> doFullFloat - , fmap ("mpv" `isPrefixOf`) title -?> doFullFloat - ] - -myKeys c = mkKeymap c $ - [ ("M-S-", spawn $ XMonad.terminal c) - , ("M-k", kill) - - , ("M-", spawn "exec $(dmenu_path | dmenu)") - , ("M-x M-e", spawn "emacsclient -c") - - , ("M-t", withFocused $ windows . W.sink) - , ("M-m", windows W.focusMaster) - , ("M-S-m", windows W.swapMaster) - - , ("M-", sendMessage $ Go R) - , ("M-", sendMessage $ Go L) - , ("M-", sendMessage $ Go U) - , ("M-", sendMessage $ Go D) - , ("M-M1-", sendMessage $ Swap R) - , ("M-M1-", sendMessage $ Swap L) - , ("M-M1-", sendMessage $ Swap U) - , ("M-M1-", sendMessage $ Swap D) - , ("M-C-", sendMessage $ Move R) - , ("M-C-", sendMessage $ Move L) - , ("M-C-", sendMessage $ Move U) - , ("M-C-", sendMessage $ Move D) - - , ("M-n", windows W.focusDown) - , ("M-p", windows W.focusUp) - , ("M-S-n", windows W.swapDown) - , ("M-S-p", windows W.swapUp) - - , ("M-,", sendMessage (IncMasterN 1)) - , ("M-.", sendMessage (IncMasterN (-1))) - - , ("M-\\", sendMessage NextLayout) - , ("M-S-\\", setLayout $ XMonad.layoutHook c) - - , ("M-+", sendMessage Shrink) - , ("M--", sendMessage Expand) - - , ("M-q", broadcastMessage ReleaseResources - >> restart "xmonad" True) - , ("C-M-q", io (exitWith ExitSuccess)) - ] ++ - - -- mod-[1..9], Switch to workspace N - -- mod-shift-[1..9], Move client to workspace N - [(m ++ k, windows $ f w) - | (w, k) <- zip (XMonad.workspaces c) (map show [1..9]) - , (m, f) <- [("M-",W.greedyView), ("M-S-",W.shift)]] - - -main :: IO () -main = do - xmproc <-spawnPipe "/usr/bin/xmobar /home/alan/.xmobarrc" - xmonad $ defaultConfig - { manageHook = myManageHook <+> manageDocks <+> manageHook defaultConfig - , layoutHook = smartBorders . avoidStruts $ layoutHook defaultConfig - , logHook = dynamicLogWithPP xmobarPP - { ppOutput = hPutStrLn xmproc - , ppTitle = xmobarColor "#859900" "" . shorten 200 - , ppCurrent = xmobarColor "#b58900" "". wrap "[" "]" - , ppHiddenNoWindows = xmobarColor "#93a1a1" "" - , ppUrgent = xmobarColor "#dc322f" "#b58900" - } - , terminal = "urxvt" - , modMask = mod4Mask - , handleEventHook = fullscreenEventHook - , keys = myKeys - } -- cgit 1.4.1