update vimrc & xmonad master
authorkremlin <ian@kremlin.cc>
Wed, 16 Nov 2016 03:26:05 +0000 (21:26 -0600)
committerkremlin <ian@kremlin.cc>
Wed, 16 Nov 2016 03:26:05 +0000 (21:26 -0600)
.vimrc
.xmonad/xmonad.hs

diff --git a/.vimrc b/.vimrc
index 3c9618e569ec975009f91409f65ecff595e4349d..6737af1c4b03f1de2a2343f6e6249054b8beb8d7 100644 (file)
--- a/.vimrc
+++ b/.vimrc
@@ -1,6 +1,13 @@
-set expandtab
+syntax on
+filetype plugin on
+
+set tags=/usr/src/sys/arch/armv7/tags
+set omnifunc=syntaxcomplete#Complete
+
+set mouse=a
 set incsearch
-set tabstop=4
+set shiftwidth=4
+set tabstop=8
 set backspace=2
 set ruler
 set smartcase
@@ -8,10 +15,51 @@ set showmatch
 set nu
 set nocp
 set nowrap
-
+set statusline+=%F\ %l\:%c
+set laststatus=2
 cmap w!! w !sudo tee > /dev/null %
 
-"execute pathogen#infect()
+map <C-]> :vsp <CR>:exec("tag ".expand("<cword>"))<CR>
 
-syntax on
+function! GenSdmmcTags()
+    TlistAddFilesRecursive ~/code/sdmmc/src/sys/arch/armv7 *.[c,h] 
+    TlistAddFilesRecursive ~/code/sdmmc/src/sys/dev *.[c,h]
+    TlistAddFilesRecursive ~/code/sdmmc/src/sys/scsi *.[c,h]
+    TlistAddFilesRecursive ~/code/sdmmc/src/sys/kern *.[c,h]
+    TlistAddFilesRecursive ~/code/sdmmc/src/sys/lib *.[c,h]
+endfunction
+
+function! SdmmcTags()
+    TlistSessionLoad /home/kremlin/sdmmc.tlist
+endfunction
+
+
+function! DoPrettyXML()
+  " save the filetype so we can restore it later
+  let l:origft = &ft
+  set ft=
+  " delete the xml header if it exists. This will
+  " permit us to surround the document with fake tags
+  " without creating invalid xml.
+  1s/<?xml .*?>//e
+  " insert fake tags around the entire document.
+  " This will permit us to pretty-format excerpts of
+  " XML that may contain multiple top-level elements.
+  0put ='<PrettyXML>'
+  $put ='</PrettyXML>'
+  silent %!xmllint --format -
+  " xmllint will insert an <?xml?> header. it's easy enough to delete
+  " if you don't want it.
+  " delete the fake tags
+  2d
+  $d
+  " restore the 'normal' indentation, which is one extra level
+  " too deep due to the extra tags we wrapped around the document.
+  silent %<
+  " back to home
+  1
+  " restore the filetype
+  exe "set ft=" . l:origft
+endfunction
+command! PrettyXML call DoPrettyXML()
 
index e189c5c8ea1c2c7ee805679c0182518ed8591c3d..cbe36615fa6c636628d399fcc6faef32af2d7654 100644 (file)
@@ -9,6 +9,8 @@ import XMonad.Layout.PerWorkspace
 import XMonad.Layout.Spacing
 import XMonad.Layout.ThreeColumns
 import XMonad.Layout.Spiral
+import XMonad.Layout.NoBorders
+--import XMonad.Layout.Fullscreen
 import Data.Ratio
 import System.IO
 
@@ -16,10 +18,11 @@ threeColLayout = ThreeCol 2 (3/100) (1/2)
 tallLayout     = Tall 1 (5/100) (2/3)
 spiralLayout   = spiral (1 % 1)
 
-mLayout = spacing 7 
+mLayout = spacing 0 
        $ tallLayout 
        ||| threeColLayout 
        ||| spiralLayout
+       ||| noBorders Full
 
 mStartupHook :: X ()
 mStartupHook = do
@@ -56,7 +59,6 @@ mManageHook = composeAll
        , className =? "steam"                --> doShift "game"
        , appName   =? "steam.sh"             --> doShift "game"
        , className =? "steam.sh"             --> doShift "game"
-       , appName   =? "gimp"                 --> doShift "extra"
        ]
 
 mWorkspaces = ["mon", "term", "www", "chat", "music", "mail", "game", "code", "extra"]