Merge branch 'master' of gitorious.org:hunner/hunners-dotfiles
Conflicts: .zshrc
This commit is contained in:
commit
2b63e41a3b
14 changed files with 669 additions and 101 deletions
14
.emacs
14
.emacs
|
|
@ -1,15 +1,15 @@
|
|||
(defconst dot-emacs (concat (getenv "HOME") "/" ".emacs.hunner.el")
|
||||
"My dot emacs file")
|
||||
"My dot emacs file")
|
||||
|
||||
(require 'bytecomp)
|
||||
(setq compiled-dot-emacs (byte-compile-dest-file dot-emacs))
|
||||
|
||||
(if (or (not (file-exists-p compiled-dot-emacs))
|
||||
(file-newer-than-file-p dot-emacs compiled-dot-emacs)
|
||||
(equal (nth 4 (file-attributes dot-emacs)) (list 0 0)))
|
||||
(load dot-emacs)
|
||||
(load compiled-dot-emacs))
|
||||
(file-newer-than-file-p dot-emacs compiled-dot-emacs)
|
||||
(equal (nth 4 (file-attributes dot-emacs)) (list 0 0)))
|
||||
(load dot-emacs)
|
||||
(load compiled-dot-emacs))
|
||||
|
||||
(add-hook 'kill-emacs-hook
|
||||
'(lambda () (and (file-newer-than-file-p dot-emacs compiled-dot-emacs)
|
||||
(byte-compile-file dot-emacs))))
|
||||
'(lambda () (and (file-newer-than-file-p dot-emacs compiled-dot-emacs)
|
||||
(byte-compile-file dot-emacs))))
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
(interactive)
|
||||
(color-theme-install
|
||||
'(color-theme-irblack
|
||||
(;; (background-color . "black")
|
||||
;; (background-mode . dark)
|
||||
((background-color . "black")
|
||||
(background-mode . dark)
|
||||
(border-color . "gray10")
|
||||
(cursor-color . "DarkOliveGreen2")
|
||||
(foreground-color . "#F6F3E8")
|
||||
|
|
@ -57,8 +57,10 @@
|
|||
(font-lock-variable-name-face ((t (:foreground "steel blue"))))
|
||||
(font-lock-warning-face ((t (:background "#CC1503" :foreground "#FFFFFF"))))
|
||||
(gui-element ((t (:background "#D4D0C8" :foreground "black"))))
|
||||
(fringe ((t (:background "grey10"))))
|
||||
(region ((t (:background "dark red"))))
|
||||
(mode-line ((t (:background "dim gray" :foreground "dark gray"))))
|
||||
(mode-line-buffer-id ((t (:bold t :background "dim gray" : foreground "dark gray" :weight bold))))
|
||||
(highlight ((t (:background "#111111"))))
|
||||
(highline-face ((t (:background "SeaGreen"))))
|
||||
(left-margin ((t (nil))))
|
||||
|
|
@ -67,6 +69,8 @@
|
|||
(show-paren-mismatch ((t (:background "#FF1100"))))
|
||||
(underline ((nil (:underline nil))))
|
||||
|
||||
;; whitespace
|
||||
(trailing-whitespace ((t (:background "gray22"))))
|
||||
;; mumamo
|
||||
;(mumamo-background-chunk-major ((t (:background "#000000"))))
|
||||
;(mumamo-background-chunk-submode ((t (:background "#222222"))))
|
||||
|
|
|
|||
110
.emacs.hunner.el
110
.emacs.hunner.el
|
|
@ -1,6 +1,6 @@
|
|||
(require 'cl)
|
||||
;; (require 'cl)
|
||||
|
||||
(mapcar (lambda (x) (add-to-list 'load-path (expand-file-name x)))
|
||||
(mapc (lambda (x) (add-to-list 'load-path (expand-file-name x)))
|
||||
'("~/.emacs.d"
|
||||
))
|
||||
|
||||
|
|
@ -12,15 +12,17 @@
|
|||
irblack
|
||||
parenface
|
||||
bar-cursor
|
||||
tls
|
||||
erc
|
||||
))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; GLOBAL
|
||||
(color-theme-initialize)
|
||||
|
||||
(if window-system
|
||||
(set-background-color "black")
|
||||
())
|
||||
;; (if window-system
|
||||
;; (set-background-color "black")
|
||||
;; ())
|
||||
(color-theme-irblack)
|
||||
;(if window-system
|
||||
; (color-theme-gentooish)
|
||||
|
|
@ -30,8 +32,15 @@
|
|||
;(load-file "~/.emacs.d/color-theme-inkpot.el")
|
||||
;(color-theme-inkpot)
|
||||
|
||||
;; OS X settings
|
||||
;; (setq mac-option-key-is-meta nil)
|
||||
;; (setq mac-command-key-is-meta t)
|
||||
;; (setq mac-command-modifier 'meta)
|
||||
;; (setq mac-option-modifier nil)
|
||||
|
||||
(bar-cursor-mode 1)
|
||||
(menu-bar-mode 0)
|
||||
(scroll-bar-mode -1)
|
||||
(tool-bar-mode 0)
|
||||
(setq linum-format "%3d ")
|
||||
(setq-default indent-tabs-mode nil)
|
||||
|
|
@ -80,8 +89,9 @@
|
|||
;; (setq url-proxy-services '(("no_proxy" . "localhost")
|
||||
;; ("http" . "localhost:8118")))
|
||||
|
||||
(setq-default save-place t) ;; activate it for all buffers
|
||||
(setq save-place-file "~/.emacs.d/saveplace") ;; keep my ~/ clean
|
||||
(setq-default save-place t) ;; activate it for all buffers
|
||||
(require 'saveplace) ;; Need to require after setq
|
||||
|
||||
(setq backup-directory-alist
|
||||
`((".*" . "~/.emacs.d/backups/")))
|
||||
|
|
@ -96,6 +106,7 @@
|
|||
;; Highlight bad whitespace
|
||||
(global-whitespace-mode t)
|
||||
(setq whitespace-style (quote (tabs tab-mark)))
|
||||
(setq-default show-trailing-whitespace t)
|
||||
|
||||
;; Make % work like vi
|
||||
(global-set-key "%" 'match-paren)
|
||||
|
|
@ -107,12 +118,12 @@
|
|||
(t (self-insert-command (or arg 1)))))
|
||||
|
||||
;; Prevent Emacs from stupidly auto-changing my working directory
|
||||
(defun find-file-save-default-directory ()
|
||||
(interactive)
|
||||
(setq saved-default-directory default-directory)
|
||||
(ido-find-file)
|
||||
(setq default-directory saved-default-directory))
|
||||
(global-set-key "\C-x\C-f" 'find-file-save-default-directory)
|
||||
;; (defun find-file-save-default-directory ()
|
||||
;; (interactive)
|
||||
;; (setq saved-default-directory default-directory)
|
||||
;; (ido-find-file)
|
||||
;; (setq default-directory saved-default-directory))
|
||||
;; (global-set-key "\C-x\C-f" 'find-file-save-default-directory)
|
||||
|
||||
;; Give killing lines advice
|
||||
(defadvice kill-ring-save (before slick-copy activate compile)
|
||||
|
|
@ -164,6 +175,7 @@
|
|||
commands))
|
||||
(set-keys '(
|
||||
("C-c t" totd)
|
||||
("C-c n" global-linum-mode)
|
||||
("C-c s p" (lambda () (interactive)
|
||||
(if (shellfm-running-p)
|
||||
(shellfm-pause)
|
||||
|
|
@ -176,8 +188,14 @@
|
|||
("C-c s a" shellfm-add-to-playlist)
|
||||
("C-c s q" shellfm 0)
|
||||
("C-c s i" shellfm-track-info)
|
||||
("C-c e" ido-erc-buffer)
|
||||
("C-S-<left>" shrink-window-horizontally)
|
||||
("C-S-<right>" enlarge-window-horizontally)
|
||||
("C-S-<down>" shrink-window)
|
||||
("C-S-<up>" enlarge-window)
|
||||
("M-s" save-buffer)
|
||||
("M-n" global-linum-mode)
|
||||
("M-p" ctrl-y-in-vi)
|
||||
("M-n" ctrl-e-in-vi)
|
||||
("M-N" make-frame)
|
||||
("M-W" delete-frame)
|
||||
("M-w" ido-kill-buffer)
|
||||
|
|
@ -190,21 +208,44 @@
|
|||
("M-O" other-window)
|
||||
("M-`" switch-to-next-frame)
|
||||
("M-~" switch-to-previous-frame)
|
||||
("M-RET" ns-toggle-fullscreen)
|
||||
))
|
||||
|
||||
;;toggle full-screen
|
||||
;; (defun toggle-fullscreen ()
|
||||
;; (interactive)
|
||||
;; (set-frame-parameter
|
||||
;; nil
|
||||
;; 'fullscreen
|
||||
;; (if (frame-parameter nil 'fullscreen)
|
||||
;; nil
|
||||
;; 'fullboth)))
|
||||
|
||||
;; (global-set-key [(meta return)] 'toggle-fullscreen)
|
||||
|
||||
;; Transparency
|
||||
(set-frame-parameter (selected-frame) 'alpha '(85 85))
|
||||
(add-to-list 'default-frame-alist '(alpha 85 85))
|
||||
;; (set-frame-font "Droid Sans Mono Dotted-12")
|
||||
(eval-when-compile (require 'cl))
|
||||
(defun toggle-transparency ()
|
||||
(interactive)
|
||||
(if (/=
|
||||
(cadr (find 'alpha (frame-parameters nil) :key #'car))
|
||||
10)
|
||||
(set-frame-parameter nil 'alpha '(10 10))
|
||||
40)
|
||||
(set-frame-parameter nil 'alpha '(40 40))
|
||||
(set-frame-parameter nil 'alpha '(85 85))))
|
||||
(global-set-key (kbd "C-c T") 'toggle-transparency)
|
||||
|
||||
;; Vim-like scrolling
|
||||
(defun ctrl-e-in-vi (n)
|
||||
(interactive "p")
|
||||
(scroll-up n))
|
||||
|
||||
(defun ctrl-y-in-vi (n)
|
||||
(interactive "p")
|
||||
(scroll-down n))
|
||||
|
||||
;; (global-set-key (kbd "<XF86AudioPlay>")
|
||||
;; (lambda () (interactive)
|
||||
;; (if (shellfm-running-p)
|
||||
|
|
@ -213,8 +254,29 @@
|
|||
|
||||
;; ERC stuff
|
||||
;; (setq erc-encoding-coding-alist (quote (("#lisp" . utf-8)
|
||||
;; ("#nihongo" . iso-2022-jp) ("#truelambda" . iso-latin-1)
|
||||
;; ("#bitlbee" . iso-latin-1))))
|
||||
;; ("#nihongo" . iso-2022-jp)
|
||||
;; ("#" . iso-latin-1)
|
||||
;; ("#" . iso-latin-1))))
|
||||
(autoload 'erc "erc")
|
||||
(add-hook 'erc-mode-hook
|
||||
'(lambda ()
|
||||
(setq scroll-margin 0)
|
||||
(setq erc-scrolltobottom-mode 1)))
|
||||
(load "~/.emacs.d/erc-bip") ;; Passwords here
|
||||
(defun ido-erc-buffer()
|
||||
(interactive)
|
||||
(switch-to-buffer
|
||||
(ido-completing-read "Channel:"
|
||||
(save-excursion
|
||||
(delq
|
||||
nil
|
||||
(mapcar (lambda (buf)
|
||||
(when (buffer-live-p buf)
|
||||
(with-current-buffer buf
|
||||
(and (eq major-mode 'erc-mode)
|
||||
(buffer-name buf)))))
|
||||
(buffer-list)))))))
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Haskell mode
|
||||
|
|
@ -282,6 +344,13 @@
|
|||
'(scroll-step 1)
|
||||
'(scroll-up-aggressively 0.0)
|
||||
'(show-paren-mode t nil (paren)))
|
||||
(custom-set-faces
|
||||
;; custom-set-faces was added by Custom.
|
||||
;; If you edit it by hand, you could mess it up, so be careful.
|
||||
;; Your init file should contain only one such instance.
|
||||
;; If there is more than one, they won't work right.
|
||||
'(mumamo-border-face-in ((t nil)))
|
||||
'(mumamo-border-face-out ((t nil))))
|
||||
|
||||
|
||||
;;; This was installed by package-install.el.
|
||||
|
|
@ -294,10 +363,3 @@
|
|||
(expand-file-name "~/.emacs.d/elpa/package.el"))
|
||||
(package-initialize)
|
||||
(require 'starter-kit-elpa))
|
||||
(custom-set-faces
|
||||
;; custom-set-faces was added by Custom.
|
||||
;; If you edit it by hand, you could mess it up, so be careful.
|
||||
;; Your init file should contain only one such instance.
|
||||
;; If there is more than one, they won't work right.
|
||||
'(mumamo-border-face-in ((t nil)))
|
||||
'(mumamo-border-face-out ((t nil))))
|
||||
|
|
|
|||
|
|
@ -1,3 +1,7 @@
|
|||
[user]
|
||||
name = Hunter Haugen
|
||||
email = h.haugen@gmail.com
|
||||
[color]
|
||||
ui = true
|
||||
[alias]
|
||||
lg = "log --pretty=format:'%C(yellow)%h%C(reset) %C(blue)%an%C(reset) %C(cyan)%cr%C(reset) %s %C(green)%d%C(reset)' --graph"
|
||||
|
|
|
|||
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -1,2 +1,3 @@
|
|||
.emacs.d/auto-save-list/*
|
||||
.emacs.d/history
|
||||
*
|
||||
|
|
|
|||
19
.muttrc
19
.muttrc
|
|
@ -1,20 +1,5 @@
|
|||
# Gmail stuff
|
||||
#set imap_user="hunter.haugen@gmail.com"
|
||||
set imap_user="hunner"
|
||||
#set imap_pass="password"
|
||||
|
||||
#set smtp_url="smtp://hunter.haugen@smtp.gmail.com:587/"
|
||||
set smtp_url="smtp://mailhost.cecs.pdx.edu:587/"
|
||||
#set ssl_min_dh_prime_bits=512
|
||||
#set smtp_pass="password"
|
||||
set from="hunner@cat.pdx.edu"
|
||||
set realname="Hunter Haugen"
|
||||
|
||||
#set folder="imaps://imap.gmail.com:993"
|
||||
set folder="imaps://mailhost.cecs.pdx.edu:993"
|
||||
set spoolfile="+INBOX"
|
||||
#set postponed="+[Gmail]/Drafts"
|
||||
#set record="+[Gmail]/Sent Mail"
|
||||
# Accound information
|
||||
source '~/.muttrc.sh|'
|
||||
|
||||
# Cache message headers for quick retrieval
|
||||
set header_cache=~/.mutt/cache/headers
|
||||
|
|
|
|||
28
.muttrc.sh
Executable file
28
.muttrc.sh
Executable file
|
|
@ -0,0 +1,28 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ x$HOST = xcz ] ; then
|
||||
echo 'set imap_user="hunter@puppetlabs.com"'
|
||||
#set imap_pass="password"
|
||||
|
||||
#set smtp_url="smtp://hunter.haugen@smtp.gmail.com:587/"
|
||||
|
||||
echo 'set folder="imaps://imap.gmail.com:993"'
|
||||
echo 'set spoolfile="+INBOX"'
|
||||
#set postponed="+[Gmail]/Drafts"
|
||||
#set record="+[Gmail]/Sent Mail"
|
||||
else
|
||||
# IMAP
|
||||
echo 'set imap_user="hunner"'
|
||||
#set imap_pass="password"
|
||||
|
||||
# SMTP
|
||||
echo 'set smtp_url="smtp://mailhost.cecs.pdx.edu:587/"'
|
||||
#set ssl_min_dh_prime_bits=512
|
||||
#set smtp_pass="password"
|
||||
echo 'set from="hunner@cat.pdx.edu"'
|
||||
echo 'set realname="Hunter Haugen"'
|
||||
|
||||
# Folders
|
||||
echo 'set folder="imaps://mailhost.cecs.pdx.edu:993"'
|
||||
echo 'set spoolfile="+INBOX"'
|
||||
fi
|
||||
|
|
@ -8,8 +8,10 @@ augroup filetypedetect
|
|||
"au! BufNewFile,BufRead *.rhtml set syn=eruby
|
||||
"au! BufNewFile,BufRead *.haml setfiletype haml
|
||||
"au! BufNewFile,BufRead *.rhtml setfiletype rhtml
|
||||
au! BufNewFile,BufRead Vagrantfile setfiletype ruby
|
||||
au! BufNewFile,BufRead *.rhtml setfiletype eruby
|
||||
au! BufNewFile,BufRead *.s setfiletype asmx86
|
||||
au! BufNewFile,BufRead *.rl setfiletype ragel
|
||||
au! BufRead,BufNewFile *.ijs,*.ijt,*.ijp,*.ijx setfiletype j
|
||||
|
||||
augroup END
|
||||
|
|
|
|||
|
|
@ -16,37 +16,66 @@ elseif exists("b:current_syntax")
|
|||
finish
|
||||
endif
|
||||
|
||||
syn region puppetDefine start="^\s*\(class\|define\|site\|node\)" end="{" contains=puppetDefType,puppetDefName,puppetDefArguments
|
||||
syn keyword puppetDefType class define site node inherits contained
|
||||
syn keyword puppetInherits inherits contained
|
||||
syn region puppetDefArguments start="(" end=")" contains=puppetArgument
|
||||
" match class/definition/node declarations
|
||||
syn region puppetDefine start="^\s*\(class\|define\|node\)\s" end="{" contains=puppetDefType,puppetDefName,puppetDefArguments,puppetNodeRe
|
||||
syn keyword puppetDefType class define node inherits contained
|
||||
syn region puppetDefArguments start="(" end=")" contained contains=puppetArgument,puppetString
|
||||
syn match puppetArgument "\w\+" contained
|
||||
syn match puppetDefName "\w\+" contained
|
||||
syn match puppetArgument "\$\w\+" contained
|
||||
syn match puppetArgument "'[^']+'" contained
|
||||
syn match puppetArgument '"[^"]+"' contained
|
||||
syn match puppetDefName "\w\+" contained
|
||||
syn match puppetNodeRe "/.*/" contained
|
||||
|
||||
syn match puppetInstance "\w\+\s*{" contains=puppetTypeBrace,puppetTypeName,puppetTypeDefault
|
||||
syn match puppetTypeBrace "{" contained
|
||||
syn match puppetTypeName "[a-z]\w*" contained
|
||||
syn match puppetTypeDefault "[A-Z]\w*" contained
|
||||
" match 'foo' in 'class foo { ...'
|
||||
" match 'foo::bar' in 'class foo::bar { ...'
|
||||
" match 'Foo::Bar' in 'Foo::Bar["..."]
|
||||
"FIXME: "Foo-bar" doesn't get highlighted as expected, although "foo-bar" does.
|
||||
syn match puppetInstance "[A-Za-z0-9_-]\+\(::[A-Za-z0-9_-]\+\)*\s*{" contains=puppetTypeName,puppetTypeDefault
|
||||
syn match puppetInstance "[A-Z][a-z_-]\+\(::[A-Z][a-z_-]\+\)*\s*[[{]" contains=puppetTypeName,puppetTypeDefault
|
||||
syn match puppetInstance "[A-Z][a-z_-]\+\(::[A-Z][a-z_-]\+\)*\s*<\?<|" contains=puppetTypeName,puppetTypeDefault
|
||||
syn match puppetTypeName "[a-z]\w*" contained
|
||||
syn match puppetTypeDefault "[A-Z]\w*" contained
|
||||
|
||||
syn match puppetParam "\w\+\s*=>" contains=puppetTypeRArrow,puppetParamName
|
||||
syn match puppetParamRArrow "=>" contained
|
||||
syn match puppetParamName "\w\+" contained
|
||||
syn match puppetVariable "$\w\+"
|
||||
syn match puppetVariable "${\w\+}"
|
||||
syn match puppetParen "("
|
||||
syn match puppetParen ")"
|
||||
syn match puppetBrace "{"
|
||||
syn match puppetBrace "}"
|
||||
" match 'foo' in 'foo => "bar"'
|
||||
syn match puppetParam "\w\+\s*[=+]>" contains=puppetParamName
|
||||
syn match puppetParamName "\w\+" contained
|
||||
|
||||
syn region puppetString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=puppetVariable
|
||||
" match 'present' in 'ensure => present'
|
||||
" match '2755' in 'mode => 2755'
|
||||
" don't match 'bar' in 'foo => bar'
|
||||
syn match puppetParam "\w\+\s*[=+]>\s*[a-z0-9]\+" contains=puppetParamString,puppetParamName
|
||||
syn match puppetParamString "[=+]>\s*\w\+" contains=puppetParamKeyword,puppetParamSpecial,puppetParamDigits contained
|
||||
syn keyword puppetParamKeyword present absent purged latest installed running stopped mounted unmounted role configured file directory link contained
|
||||
syn keyword puppetParamSpecial true false undef contained
|
||||
syn match puppetParamDigits "[0-9]\+"
|
||||
|
||||
syn keyword puppetBoolean true false
|
||||
syn keyword puppetKeyword import inherits include
|
||||
syn keyword puppetControl case default
|
||||
" match 'template' in 'content => template("...")'
|
||||
syn match puppetParam "\w\+\s*[=+]>\s*\w\+\s*(" contains=puppetFunction,puppetParamName
|
||||
" statements
|
||||
syn region puppetFunction start="^\s*\(alert\|crit\|debug\|emerg\|err\|fail\|include\|info\|notice\|realize\|require\|search\|tag\|warning\)\s*(" end=")" contained contains=puppetString
|
||||
" rvalues
|
||||
syn region puppetFunction start="^\s*\(defined\|file\|fqdn_rand\|generate\|inline_template\|regsubst\|sha1\|shellquote\|split\|sprintf\|tagged\|template\|versioncmp\)\s*(" end=")" contained contains=puppetString
|
||||
|
||||
syn match puppetVariable "$[a-zA-Z0-9_:]\+"
|
||||
syn match puppetVariable "${[a-zA-Z0-9_:]\+}"
|
||||
|
||||
" match anything between simple/double quotes.
|
||||
" don't match variables if preceded by a backslash.
|
||||
syn region puppetString start=+'+ skip=+\\\\\|\\'+ end=+'+
|
||||
syn region puppetString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=puppetVariable,puppetNotVariable
|
||||
syn match puppetString "/[^/]*/"
|
||||
syn match puppetNotVariable "\\$\w\+" contained
|
||||
syn match puppetNotVariable "\\${\w\+}" contained
|
||||
|
||||
syn keyword puppetKeyword import inherits include
|
||||
syn keyword puppetControl case default if else elsif
|
||||
syn keyword puppetSpecial true false undef
|
||||
|
||||
" comments last overriding everything else
|
||||
syn match puppetComment "\s*#.*$" contains=puppetTodo
|
||||
syn keyword puppetTodo TODO NOTE FIXME XXX contained
|
||||
syn match puppetComment "\s*#.*$" contains=puppetTodo
|
||||
syn region puppetComment start="/\*" end="\*/" contains=puppetTodo extend
|
||||
syn keyword puppetTodo TODO NOTE FIXME XXX BUG HACK contained
|
||||
|
||||
" Define the default highlighting.
|
||||
" For version 5.7 and earlier: only when not done already
|
||||
|
|
@ -60,25 +89,25 @@ if version >= 508 || !exists("did_puppet_syn_inits")
|
|||
endif
|
||||
|
||||
HiLink puppetVariable Identifier
|
||||
HiLink puppetBoolean Boolean
|
||||
HiLink puppetType Identifier
|
||||
HiLink puppetDefault Identifier
|
||||
HiLink puppetKeyword Define
|
||||
HiLink puppetTypeDefs Define
|
||||
HiLink puppetComment Comment
|
||||
HiLink puppetString String
|
||||
HiLink puppetParamKeyword String
|
||||
HiLink puppetParamDigits String
|
||||
HiLink puppetNotVariable String
|
||||
HiLink puppetParamSpecial Special
|
||||
HiLink puppetSpecial Special
|
||||
HiLink puppetTodo Todo
|
||||
" HiLink puppetBrace Delimiter
|
||||
" HiLink puppetTypeBrace Delimiter
|
||||
" HiLink puppetParen Delimiter
|
||||
HiLink puppetDelimiter Delimiter
|
||||
HiLink puppetControl Statement
|
||||
HiLink puppetDefType Define
|
||||
HiLink puppetDefName Type
|
||||
HiLink puppetNodeRe Type
|
||||
HiLink puppetTypeName Statement
|
||||
HiLink puppetTypeDefault Type
|
||||
HiLink puppetParamName Identifier
|
||||
HiLink puppetArgument Identifier
|
||||
HiLink puppetFunction Function
|
||||
|
||||
delcommand HiLink
|
||||
endif
|
||||
|
|
|
|||
149
.vim/syntax/ragel.vim
Normal file
149
.vim/syntax/ragel.vim
Normal file
|
|
@ -0,0 +1,149 @@
|
|||
" Vim syntax file
|
||||
"
|
||||
" Language: Ragel
|
||||
" Author: Adrian Thurston
|
||||
|
||||
syntax clear
|
||||
|
||||
"
|
||||
" Outside code
|
||||
"
|
||||
|
||||
" Comments
|
||||
syntax region ocComment start="\/\*" end="\*\/"
|
||||
syntax match ocComment "\/\/.*$"
|
||||
|
||||
" Anything preprocessor
|
||||
syntax match ocPreproc "#\(.\|\\\n\)*$"
|
||||
syntax region ocPreproc start="#" end="[^\\]$"
|
||||
|
||||
" Strings
|
||||
syntax match ocLiteral "'\(\\.\|[^'\\]\)*'"
|
||||
syntax match ocLiteral "\"\(\\.\|[^\"\\]\)*\""
|
||||
|
||||
" C/C++ Keywords
|
||||
syntax keyword ocType unsigned signed void char short int long float double bool
|
||||
syntax keyword ocType inline static extern register const volatile auto
|
||||
syntax keyword ocType union enum struct class typedef
|
||||
syntax keyword ocType namespace template typename mutable
|
||||
syntax keyword ocKeyword break continue default do else for
|
||||
syntax keyword ocKeyword goto if return switch while
|
||||
syntax keyword ocKeyword new delete this using friend public private protected sizeof
|
||||
syntax keyword ocKeyword throw try catch operator typeid
|
||||
syntax keyword ocKeyword and bitor xor compl bitand and_eq or_eq xor_eq not not_eq
|
||||
syntax keyword ocKeyword static_cast dynamic_cast
|
||||
|
||||
" Numbers
|
||||
syntax match ocNumber "[0-9][0-9]*"
|
||||
syntax match ocNumber "0x[0-9a-fA-F][0-9a-fA-F]*"
|
||||
|
||||
" Booleans
|
||||
syntax keyword ocBoolean true false
|
||||
|
||||
" Identifiers
|
||||
syntax match anyId "[a-zA-Z_][a-zA-Z_0-9]*"
|
||||
|
||||
" Inline code only
|
||||
syntax keyword fsmType fpc fc fcurs fbuf fblen ftargs fstack
|
||||
syntax keyword fsmKeyword fhold fgoto fcall fret fentry fnext fexec fbreak
|
||||
|
||||
syntax cluster rlItems contains=rlComment,rlLiteral,rlAugmentOps,rlOtherOps,rlKeywords,rlWrite,rlCodeCurly,rlCodeSemi,rlNumber,anyId,rlLabelColon,rlExprKeywords
|
||||
|
||||
syntax region machineSpec1 matchgroup=beginRL start="%%{" end="}%%" contains=@rlItems
|
||||
syntax region machineSpec2 matchgroup=beginRL start="%%[^{]"rs=e-1 end="$" keepend contains=@rlItems
|
||||
syntax region machineSpec2 matchgroup=beginRL start="%%$" end="$" keepend contains=@rlItems
|
||||
|
||||
" Comments
|
||||
syntax match rlComment "#.*$" contained
|
||||
|
||||
" Literals
|
||||
syntax match rlLiteral "'\(\\.\|[^'\\]\)*'[i]*" contained
|
||||
syntax match rlLiteral "\"\(\\.\|[^\"\\]\)*\"[i]*" contained
|
||||
syntax match rlLiteral /\/\(\\.\|[^\/\\]\)*\/[i]*/ contained
|
||||
syntax match rlLiteral "\[\(\\.\|[^\]\\]\)*\]" contained
|
||||
|
||||
" Numbers
|
||||
syntax match rlNumber "[0-9][0-9]*" contained
|
||||
syntax match rlNumber "0x[0-9a-fA-F][0-9a-fA-F]*" contained
|
||||
|
||||
" Operators
|
||||
syntax match rlAugmentOps "[>$%@]" contained
|
||||
syntax match rlAugmentOps "<>\|<" contained
|
||||
syntax match rlAugmentOps "[>\<$%@][!\^/*~]" contained
|
||||
syntax match rlAugmentOps "[>$%]?" contained
|
||||
syntax match rlAugmentOps "<>[!\^/*~]" contained
|
||||
syntax match rlAugmentOps "=>" contained
|
||||
syntax match rlOtherOps "->" contained
|
||||
|
||||
syntax match rlOtherOps ":>" contained
|
||||
syntax match rlOtherOps ":>>" contained
|
||||
syntax match rlOtherOps "<:" contained
|
||||
|
||||
" Keywords
|
||||
" FIXME: Enable the range keyword post 5.17.
|
||||
" syntax keyword rlKeywords machine action context include range contained
|
||||
syntax keyword rlKeywords machine action context include import export prepush postpop contained
|
||||
syntax keyword rlExprKeywords when inwhen outwhen err lerr eof from to contained
|
||||
|
||||
" Case Labels
|
||||
syntax keyword caseLabelKeyword case contained
|
||||
syntax cluster caseLabelItems contains=ocComment,ocPreproc,ocLiteral,ocType,ocKeyword,caseLabelKeyword,ocNumber,ocBoolean,anyId,fsmType,fsmKeyword
|
||||
syntax match caseLabelColon "case" contains=@caseLabelItems
|
||||
syntax match caseLabelColon "case[\t ]\+.*:$" contains=@caseLabelItems
|
||||
syntax match caseLabelColon "case[\t ]\+.*:[^=:]"me=e-1 contains=@caseLabelItems
|
||||
|
||||
" Labels
|
||||
syntax match ocLabelColon "^[\t ]*[a-zA-Z_][a-zA-Z_0-9]*[ \t]*:$" contains=anyLabel
|
||||
syntax match ocLabelColon "^[\t ]*[a-zA-Z_][a-zA-Z_0-9]*[ \t]*:[^=:]"me=e-1 contains=anyLabel
|
||||
|
||||
syntax match rlLabelColon "[a-zA-Z_][a-zA-Z_0-9]*[ \t]*:$" contained contains=anyLabel
|
||||
syntax match rlLabelColon "[a-zA-Z_][a-zA-Z_0-9]*[ \t]*:[^=:>]"me=e-1 contained contains=anyLabel
|
||||
syntax match anyLabel "[a-zA-Z_][a-zA-Z_0-9]*" contained
|
||||
|
||||
" All items that can go in a code block.
|
||||
|
||||
syntax cluster inlineItems contains=rlCodeCurly,ocComment,ocPreproc,ocLiteral,ocType,ocKeyword,ocNumber,ocBoolean,ocLabelColon,anyId,fsmType,fsmKeyword,caseLabelColon
|
||||
|
||||
" Blocks of code. rlCodeCurly is recursive.
|
||||
syntax region rlCodeCurly matchgroup=NONE start="{" end="}" contained contains=@inlineItems
|
||||
syntax region rlCodeSemi matchgroup=Type start="\<alphtype\>" start="\<getkey\>" start="\<access\>" start="\<variable\>" matchgroup=NONE end=";" contained contains=@inlineItems
|
||||
|
||||
syntax region rlWrite matchgroup=Type start="\<write\>" matchgroup=NONE end="[;)]" contained contains=rlWriteKeywords,rlWriteOptions
|
||||
|
||||
syntax keyword rlWriteKeywords init data exec exports start error first_final contained
|
||||
syntax keyword rlWriteOptions noerror nofinal noprefix noend nocs contained
|
||||
|
||||
"
|
||||
" Sync at the start of machine specs.
|
||||
"
|
||||
" Match The ragel delimiters only if there quotes no ahead on the same line.
|
||||
" On the open marker, use & to consume the leader.
|
||||
syntax sync match ragelSyncPat grouphere NONE "^[^\'\"%]*%%{&^[^\'\"%]*"
|
||||
syntax sync match ragelSyncPat grouphere NONE "^[^\'\"%]*%%[^{]&^[^\'\"%]*"
|
||||
syntax sync match ragelSyncPat grouphere NONE "^[^\'\"]*}%%"
|
||||
|
||||
"
|
||||
" Specifying Groups
|
||||
"
|
||||
hi link ocComment Comment
|
||||
hi link ocPreproc Macro
|
||||
hi link ocLiteral String
|
||||
hi link ocType Type
|
||||
hi link ocKeyword Keyword
|
||||
hi link ocNumber Number
|
||||
hi link ocBoolean Boolean
|
||||
hi link rlComment Comment
|
||||
hi link rlNumber Number
|
||||
hi link rlLiteral String
|
||||
hi link rlAugmentOps Keyword
|
||||
hi link rlExprKeywords Keyword
|
||||
hi link rlWriteKeywords Keyword
|
||||
hi link rlWriteOptions Keyword
|
||||
hi link rlKeywords Type
|
||||
hi link fsmType Type
|
||||
hi link fsmKeyword Keyword
|
||||
hi link anyLabel Label
|
||||
hi link caseLabelKeyword Keyword
|
||||
hi link beginRL Type
|
||||
|
||||
let b:current_syntax = "ragel"
|
||||
12
.vimrc
12
.vimrc
|
|
@ -305,6 +305,10 @@ endif
|
|||
|
||||
" content creation
|
||||
if has("autocmd")
|
||||
augroup puppet
|
||||
autocmd BufRead,BufNewFile *.pp
|
||||
\ set tabstop=2 shiftwidth=2 softtabstop=2
|
||||
augroup END
|
||||
augroup text
|
||||
autocmd BufRead,BufNewFile *.txt
|
||||
\ set nonumber tw=80
|
||||
|
|
@ -513,8 +517,10 @@ endif
|
|||
" Go to buffers
|
||||
nmap <silent> <S-Left> :bprev<CR>
|
||||
nmap <silent> <S-Right> :bnext<CR>
|
||||
nmap <C-w>, :bp<CR>
|
||||
nmap <C-w>. :bn<CR>
|
||||
nmap <C-w>, :bprev<CR>
|
||||
nmap <C-w>. :bnext<CR>
|
||||
nmap gT :bprev<CR>
|
||||
nmap gt :bnext<CR>
|
||||
|
||||
" v_K is really really annoying
|
||||
vmap K k
|
||||
|
|
@ -977,7 +983,7 @@ au Filetype html,xml,xsl,sgml ",docbook
|
|||
" explorador vertical
|
||||
let g:explVertical=1
|
||||
" define leader como =
|
||||
let mapleader = "="
|
||||
"let mapleader = "="
|
||||
|
||||
" Terminal companability
|
||||
map <F15> <S-F3>
|
||||
|
|
|
|||
|
|
@ -71,10 +71,10 @@ mKeys = [ ("M-S-n", sendMessage MirrorShrink ) -- Expand current window
|
|||
, ("M-S-g", warpToCentre >> goToSelected gsConfig )
|
||||
|
||||
-- Multimedia
|
||||
, ("<XF86AudioPlay>" , spawn "cmus-remote --pause" ) -- play/pause mpd
|
||||
, ("<XF86AudioStop>" , spawn "cmus-remote --stop" ) -- stop mpd
|
||||
, ("<XF86AudioPrev>" , spawn "cmus-remote --prev" ) -- prev song
|
||||
, ("<XF86AudioNext>" , spawn "cmus-remote --next" ) -- next song
|
||||
, ("<XF86AudioPlay>" , spawn "mpc toggle" ) -- play/pause mpd
|
||||
, ("<XF86AudioStop>" , spawn "mpc stop" ) -- stop mpd
|
||||
, ("<XF86AudioPrev>" , spawn "mpc prev" ) -- prev song
|
||||
, ("<XF86AudioNext>" , spawn "mpc next" ) -- next song
|
||||
, ("<XF86AudioLowerVolume>", spawn "amixer -q set PCM 1-") -- volume down
|
||||
, ("<XF86AudioRaiseVolume>", spawn "amixer -q set PCM 1+") -- volume up
|
||||
, ("<XF86AudioMute>" , spawn "amixer -q set Headphone toggle") -- toggle mute
|
||||
|
|
|
|||
246
.zsh/func/zgitinit
Normal file
246
.zsh/func/zgitinit
Normal file
|
|
@ -0,0 +1,246 @@
|
|||
##
|
||||
## Load with `autoload -U zgitinit; zgitinit'
|
||||
##
|
||||
|
||||
typeset -gA zgit_info
|
||||
zgit_info=()
|
||||
|
||||
zgit_chpwd_hook() {
|
||||
zgit_info_update
|
||||
}
|
||||
|
||||
zgit_preexec_hook() {
|
||||
if [[ $2 == git\ * ]] || [[ $2 == *\ git\ * ]]; then
|
||||
zgit_precmd_do_update=1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_precmd_hook() {
|
||||
if [ $zgit_precmd_do_update ]; then
|
||||
unset zgit_precmd_do_update
|
||||
zgit_info_update
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_info_update() {
|
||||
zgit_info=()
|
||||
|
||||
local gitdir="$(git rev-parse --git-dir 2>/dev/null)"
|
||||
if [ $? -ne 0 ] || [ -z "$gitdir" ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
zgit_info[dir]=$gitdir
|
||||
zgit_info[bare]=$(git rev-parse --is-bare-repository)
|
||||
zgit_info[inwork]=$(git rev-parse --is-inside-work-tree)
|
||||
}
|
||||
|
||||
zgit_isgit() {
|
||||
if [ -z "$zgit_info[dir]" ]; then
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_inworktree() {
|
||||
zgit_isgit || return
|
||||
if [ "$zgit_info[inwork]" = "true" ]; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_isbare() {
|
||||
zgit_isgit || return
|
||||
if [ "$zgit_info[bare]" = "true" ]; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_head() {
|
||||
zgit_isgit || return 1
|
||||
|
||||
if [ -z "$zgit_info[head]" ]; then
|
||||
local name=''
|
||||
name=$(git symbolic-ref -q HEAD)
|
||||
if [ $? -eq 0 ]; then
|
||||
if [[ $name == refs/(heads|tags)/* ]]; then
|
||||
name=${name#refs/(heads|tags)/}
|
||||
fi
|
||||
else
|
||||
name=$(git name-rev --name-only --no-undefined --always HEAD)
|
||||
if [ $? -ne 0 ]; then
|
||||
return 1
|
||||
elif [[ $name == remotes/* ]]; then
|
||||
name=${name#remotes/}
|
||||
fi
|
||||
fi
|
||||
zgit_info[head]=$name
|
||||
fi
|
||||
|
||||
echo $zgit_info[head]
|
||||
}
|
||||
|
||||
zgit_branch() {
|
||||
zgit_isgit || return 1
|
||||
zgit_isbare && return 1
|
||||
|
||||
if [ -z "$zgit_info[branch]" ]; then
|
||||
local branch=$(git symbolic-ref HEAD 2>/dev/null)
|
||||
if [ $? -eq 0 ]; then
|
||||
branch=${branch##*/}
|
||||
else
|
||||
branch=$(git name-rev --name-only --always HEAD)
|
||||
fi
|
||||
zgit_info[branch]=$branch
|
||||
fi
|
||||
|
||||
echo $zgit_info[branch]
|
||||
return 0
|
||||
}
|
||||
|
||||
zgit_tracking_remote() {
|
||||
zgit_isgit || return 1
|
||||
zgit_isbare && return 1
|
||||
|
||||
local branch
|
||||
if [ -n "$1" ]; then
|
||||
branch=$1
|
||||
elif [ -z "$zgit_info[branch]" ]; then
|
||||
branch=$(zgit_branch)
|
||||
[ $? -ne 0 ] && return 1
|
||||
else
|
||||
branch=$zgit_info[branch]
|
||||
fi
|
||||
|
||||
local k="tracking_$branch"
|
||||
local remote
|
||||
if [ -z "$zgit_info[$k]" ]; then
|
||||
remote=$(git config branch.$branch.remote)
|
||||
zgit_info[$k]=$remote
|
||||
fi
|
||||
|
||||
echo $zgit_info[$k]
|
||||
return 0
|
||||
}
|
||||
|
||||
zgit_tracking_merge() {
|
||||
zgit_isgit || return 1
|
||||
zgit_isbare && return 1
|
||||
|
||||
local branch
|
||||
if [ -z "$zgit_info[branch]" ]; then
|
||||
branch=$(zgit_branch)
|
||||
[ $? -ne 0 ] && return 1
|
||||
else
|
||||
branch=$zgit_info[branch]
|
||||
fi
|
||||
|
||||
local remote=$(zgit_tracking_remote $branch)
|
||||
[ $? -ne 0 ] && return 1
|
||||
if [ -n "$remote" ]; then # tracking branch
|
||||
local merge=$(git config branch.$branch.merge)
|
||||
if [ $remote != "." ]; then
|
||||
merge=$remote/$(basename $merge)
|
||||
fi
|
||||
echo $merge
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_isindexclean() {
|
||||
zgit_isgit || return 1
|
||||
if git diff --quiet --cached 2>/dev/null; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_isworktreeclean() {
|
||||
zgit_isgit || return 1
|
||||
if git diff --quiet 2>/dev/null; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_hasuntracked() {
|
||||
zgit_isgit || return 1
|
||||
local -a flist
|
||||
flist=($(git ls-files --others --exclude-standard))
|
||||
if [ $#flist -gt 0 ]; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_hasunmerged() {
|
||||
zgit_isgit || return 1
|
||||
local -a flist
|
||||
flist=($(git ls-files -u))
|
||||
if [ $#flist -gt 0 ]; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
zgit_svnhead() {
|
||||
zgit_isgit || return 1
|
||||
|
||||
local commit=$1
|
||||
if [ -z "$commit" ]; then
|
||||
commit='HEAD'
|
||||
fi
|
||||
|
||||
git show --raw $commit | \
|
||||
grep git-svn-id | \
|
||||
sed -re 's/^\s*git-svn-id: .*@([0-9]+).*$/\1/'
|
||||
}
|
||||
|
||||
zgit_rebaseinfo() {
|
||||
zgit_isgit || return 1
|
||||
if [ -d $zgit_info[dir]/rebase-merge ]; then
|
||||
dotest=$zgit_info[dir]/rebase-merge
|
||||
elif [ -d $zgit_info[dir]/.dotest-merge ]; then
|
||||
dotest=$zgit_info[dir]/.dotest-merge
|
||||
elif [ -d .dotest ]; then
|
||||
dotest=.dotest
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
|
||||
zgit_info[dotest]=$dotest
|
||||
|
||||
zgit_info[rb_onto]=$(cat "$dotest/onto")
|
||||
if [ -f "$dotest/upstream" ]; then
|
||||
zgit_info[rb_upstream]=$(cat "$dotest/upstream")
|
||||
else
|
||||
zgit_info[rb_upstream]=
|
||||
fi
|
||||
if [ -f "$dotest/orig-head" ]; then
|
||||
zgit_info[rb_head]=$(cat "$dotest/orig-head")
|
||||
elif [ -f "$dotest/head" ]; then
|
||||
zgit_info[rb_head]=$(cat "$dotest/head")
|
||||
fi
|
||||
zgit_info[rb_head_name]=$(cat "$dotest/head-name")
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
chpwd_functions+=zgit_chpwd_hook
|
||||
preexec_functions+=zgit_preexec_hook
|
||||
precmd_functions+=zgit_precmd_hook
|
||||
|
||||
zgit_info_update
|
||||
|
||||
# vim:set ft=zsh:
|
||||
70
.zshrc
70
.zshrc
|
|
@ -1,9 +1,16 @@
|
|||
typeset -ga preexec_functions
|
||||
typeset -ga precmd_functions
|
||||
typeset -ga chpwd_functions
|
||||
fpath=($fpath $HOME/.zsh/func)
|
||||
#typeset -u fpath
|
||||
|
||||
# Options
|
||||
setopt appendhistory hist_ignore_space hist_ignore_all_dups extendedglob nomatch notify dvorak # correct
|
||||
unsetopt beep
|
||||
bindkey -e
|
||||
|
||||
zstyle :compinstall filename '~/.zshrc'
|
||||
autoload -Uz compinit
|
||||
autoload -Uz compinit colors zgitinit && colors && zgitinit
|
||||
compinit -u
|
||||
#bindkey '^L' push-line
|
||||
bindkey "^I" expand-or-complete-prefix
|
||||
|
|
@ -28,7 +35,8 @@ paths=(/cat/bin /cat/games/bin /opt/csw/sbin /opt/csw/bin
|
|||
/opt/SUNWut/sbin /opt/SUNWut/bin /usr/ccs/bin /usr/local/bin /usr/openwin/bin
|
||||
/usr/bin/X11 /usr/local/bin/X11 /usr/openwin/lib/X11/xkb /usr/openwin/bin/xview /opt/java/bin
|
||||
/opt/java5/bin /opt/java/jre/bin /opt/openoffice/program)
|
||||
prepaths=(~/.cabal/bin ~/local/bin ~/local/sbin ~/local/share/bin)
|
||||
prepaths=(/opt/local/sbin /opt/local/bin ~/.cabal/bin ~/local/bin ~/local/sbin
|
||||
~/local/share/bin)
|
||||
for dir in $paths ; do
|
||||
if [ -d $dir ] ; then
|
||||
export PATH=$PATH:$dir
|
||||
|
|
@ -56,20 +64,42 @@ fi
|
|||
if [ -d ~/.gems/bin ] ; then
|
||||
export PATH="$HOME/.gems/bin:$PATH"
|
||||
fi
|
||||
if [ -d ~/.gem/ruby/1.8/bin ] ; then
|
||||
export PATH="$PATH:$HOME/.gem/ruby/1.8/bin"
|
||||
fi
|
||||
#for dir in `find /opt/*/bin|grep /bin$` `find /opt/csw/*/bin|grep /bin$` ; do
|
||||
# export PATH=$PATH:$dir
|
||||
#done
|
||||
|
||||
# Setting vars
|
||||
#TERM=rxvt
|
||||
export GEM_HOME="$HOME/.gems"
|
||||
export GEM_PATH="$GEM_HOME:/usr/lib/ruby/gems/1.8"
|
||||
#export GEM_HOME="$HOME/.gems"
|
||||
#export GEM_PATH="$GEM_HOME:/usr/lib/ruby/gems/1.8"
|
||||
zshhosts=(serenity.cat.pdx.edu hunner@mint.cic.pdx.edu drkatz.cat.pdx.edu walt.ece.pdx.edu bunny.cat.pdx.edu spof.cat.pdx.edu fops.cat.pdx.edu narsil.cat.pdx.edu hunner@odin.pdx.edu hunnur@alcmaeonllc.com mir.cat.pdx.edu geppetto.cat.pdx.edu)
|
||||
HISTSIZE=1000
|
||||
SAVEHIST=1000
|
||||
HISTFILE=~/.history
|
||||
export GPGKEY="48C7AF0C"
|
||||
PS1="%m%# "
|
||||
|
||||
# Prompt
|
||||
#PS1="%m%# "
|
||||
prompt_precmd() {
|
||||
gitcolor=""
|
||||
if zgit_isgit ; then
|
||||
if ! zgit_isindexclean ; then
|
||||
#PROMPT="[%F{$usercolor}%n%F{white}@%F{$hostcolor}%m%F{white}:%F{blue}%~%f](%F{cyan}$(zgit_branch)%f)>"
|
||||
gitcolor=$fg[blue]
|
||||
elif ! zgit_isworktreeclean ; then
|
||||
#PROMPT="[%F{$usercolor}%n%F{white}@%F{$hostcolor}%m%F{white}:%F{blue}%~%f]>"
|
||||
gitcolor=$fg[green]
|
||||
fi
|
||||
fi
|
||||
color="%(?.$gitcolor.$fg[red])"
|
||||
PROMPT="%m$color%#%{$reset_color%} "
|
||||
}
|
||||
#precmd_functions+=prompt_precmd
|
||||
PROMPT="%m%# "
|
||||
|
||||
if [ `uname -s` = "SunOS" ] ; then
|
||||
export LANG="C"
|
||||
else
|
||||
|
|
@ -114,6 +144,9 @@ else
|
|||
export VISUAL=vi
|
||||
export EDITOR=vi
|
||||
fi
|
||||
if [ -n "$SSH_AUTH_SOCK" ] ; then
|
||||
ln -fs $SSH_AUTH_SOCK $HOME/.ssh-agent
|
||||
fi
|
||||
#xset fp+ /usr/APL2/fonts/X11
|
||||
#xset fp rehash
|
||||
#if [ -d $HOME/.gems/gems ] ; then
|
||||
|
|
@ -132,6 +165,7 @@ alias ll="l -Fl"
|
|||
alias la="l -Fa"
|
||||
alias lla="ll -Fa"
|
||||
alias c="cd"
|
||||
cl() { cd $@ && ls }
|
||||
alias e="TERM=rxvt-256color; emacs -nw"
|
||||
alias et="TERM=rxvt-256color; emacsclient -t"
|
||||
alias ec="emacsclient -c --eval '(set-background-color \"black\")'"
|
||||
|
|
@ -145,7 +179,7 @@ alias m="TERM=rxvt;ssh hunner@mint.cic.pdx.edu"
|
|||
alias chandra="TERM=rxvt;ssh hunner@chandra.cs.pdx.edu"
|
||||
export CS=cs.pdx.edu
|
||||
alias odin="TERM=xterm;ssh hunner@odin.pdx.edu"
|
||||
alias clancy="ssh hunnur@clancy.dreamhost.com"
|
||||
alias budda="ssh hunnur@budda.dreamhost.com"
|
||||
alias kvar="ssh hunner@131.252.134.134"
|
||||
alias kvin="ssh hunner@131.252.135.22"
|
||||
alias mutt="TERM=xterm-256color mutt"
|
||||
|
|
@ -154,13 +188,13 @@ alias gpg-add="/usr/libexec/gpg-preset-passphrase"
|
|||
alias rsync="rsync -azPHe ssh" #-a equals -rlptgoD
|
||||
alias mang="cd ~/zips/mangband ; DISPLAY=\"\" ./mangclient"
|
||||
alias nh="export HISTFILE=/dev/null"
|
||||
alias cl="co -l"
|
||||
#alias cl="co -l"
|
||||
alias cu="ci -u"
|
||||
alias sl="screen -ls"
|
||||
alias sr="screen -r"
|
||||
alias sx="screen -x"
|
||||
alias srd="screen -rd"
|
||||
alias t="SSH_AUTH_SOCK=$HOME/.tmux-ssh-agent TERM=xterm-256color tmux at"
|
||||
alias t="SSH_AUTH_SOCK=$HOME/.ssh-agent TERM=xterm-256color tmux at"
|
||||
alias tl="tmux ls"
|
||||
alias bc="bc -q"
|
||||
alias fm="fmstatus.sh&;shell-fm"
|
||||
|
|
@ -169,8 +203,26 @@ alias d="dtach -a /tmp/dtach"
|
|||
alias eo="xmodmap ~/keymaps/eo_dv_hunner.pke"
|
||||
alias vt="export TERM=vt220"
|
||||
alias rm=rm; unalias rm #hack
|
||||
alias gem="nice -n19 gem"
|
||||
alias g="git"
|
||||
alias gl="git lg"
|
||||
alias gp="git push"
|
||||
alias gu="git pull"
|
||||
alias gs="git status"
|
||||
alias gm="git mv"
|
||||
alias gr="git r"
|
||||
alias ga="git add"
|
||||
alias gaf="git add --force"
|
||||
alias gb="git branch"
|
||||
alias gc="git commit"
|
||||
alias gca="git commit --amend"
|
||||
alias gd="git diff"
|
||||
alias go="git checkout"
|
||||
alias gob="git checkout -b"
|
||||
alias gk="gitk --all&"
|
||||
alias gx="gitx --all"
|
||||
alias uzbl="uzbl-browser"
|
||||
alias hide="SetFile -a V"
|
||||
alias show="SetFile -a v"
|
||||
#startup aliases
|
||||
alias -s pdf="zathura"
|
||||
alias -s txt="vi"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue