Permalink
Browse files

add .vimperator submodule

  • Loading branch information...
1 parent 3d8d387 commit 69f84328d4238aedd15472f29a504844085712d8 @linsong committed Aug 6, 2010
Showing with 5 additions and 126 deletions.
  1. +3 −0 .gitmodules
  2. +1 −0 .vimperator
  3. +0 −126 .vimperatorrc
  4. +1 −0 .vimperatorrc
View
3 .gitmodules
@@ -4,3 +4,6 @@
[submodule ".mutt"]
path = .mutt
url = git@github.com:linsong/mutt-config.git
+[submodule ".vimperator"]
+ path = .vimperator
+ url = git@github.com:linsong/vimperator-config.git
1 .vimperator
@@ -0,0 +1 @@
+Subproject commit a4ddebeef9805e222f722c397116962c251c0637
View
126 .vimperatorrc
@@ -1,126 +0,0 @@
-" settings
-
-set guioptions+=m
-" use the firefox awesomebar style hints
-set wildoptions=auto
-set complete=l
-"set complete=sbhfS
-
-"should match the name set in ":dialog searchengine" dialog
-"set defsearch=google
-set defsearch=g
-set hlsearch
-set incsearch
-set smartcase
-
-set showmode
-set showstatuslinks
-
-set nextpattern+=^\s*下一页\s*$,^\s*下一张\s*$,^››$
-set previouspattern+=^\s*上一页\s*$,^\s*上一张\s*$,^‹‹$
-
-"set wildmode=list:longest
-
-"Allow user to click in address bar.
-set! browser.urlbar.clickSelectsAll=true
-set! browser.urlbar.doubleClickSelectsAll=true
-
-" key mappings {{{1
-" resource the rc file
-:map ,s :source ~/.vimperatorrc<CR>
-
-:map <A-n> :tabnew<CR>
-:map <A-.> :tabnext<CR>
-:map <A-,> :tabprev<CR>
-:map <A-q> :tabclose<CR>
-
-"Map paste operation normally.
-imap <C-v> <C-v>
-
-" use c-n and c-p to go up and down in insert and command mode
-imap <C-n> <down>
-imap <C-p> <up>
-cmap <C-n> <down>
-cmap <C-p> <up>
-
-:command! -nargs=* g open google <args>
-:map ,g :g
-
-" web developers menu shortcut mapping
-:map ,wc :emenu Tools.Web Developer.Cookies.Delete Path Cookies<CR>
-
-" firebug menu shortcut mapping
-:map ,fb :emenu Tools.Firebug.Open Firebug<CR>
-:map ,fi :emenu Tools.Firebug.Inspect Element<CR>
-:map ,fl :emenu Tools.Firebug.Command Line<CR>
-
-" look up word in dict.cn
-:command! dict -nargs=* tabopen http://dict.cn/<args>
-:map w :dict
-:map <silent> W :exe ":dict "+content.getSelection()<CR>
-
-:map ,lh :emenu Tools.Live HTTP headers<CR>
-
-" }}}1
-
-" autocommands {{{1
-"au LocationChange .* :js modes.passAllKeys = /mail\.google\.com/.test(buffer.URL)
-au LocationChange .* :js modes.passAllKeys = /www\.google\.com\/reader/.test(buffer.URL)
-
-"" for Linux
-"":au LocationChange .* :set editor=gvim -f
-"":au LocationChange mail\.google\.com :set editor=gvim -f -c 'set ft=mail'
-" for MacOSX
-":set editor=open -W -n -t
-
-" }}}1
-
-" Changing the command line color when focused
-javascript <<EOM
- (function() {
- var inputElement = document.getElementById('liberator-commandline-command');
- function swapBGColor(event) {
- inputElement.parentNode.style.backgroundColor = event.type == "focus" ? "yellow" : "";
- }
- inputElement.addEventListener('focus', swapBGColor, false);
- inputElement.addEventListener('blur', swapBGColor, false);
- })();
-EOM
-
-" Toggle element
-:js << EOF
- toggle_element = function (name){
- document.getElementById(name).collapsed ^= 1;
- }
-EOF
-
-" Toggle webdeveloper toolbar
-map <C-T> :js toggle_element('webdeveloper-toolbar')<CR>
-
-javascript <<EOF
-(function(){
- var feedPanel = document.createElement("statusbarpanel");
- feedPanel.setAttribute("id", "feed-panel-clone");
- feedPanel.appendChild(document.getElementById("feed-button"));
- feedPanel.firstChild.setAttribute("style", "padding: 0; max-height: 16px;");
- document.getElementById("status-bar")
- .insertBefore(feedPanel, document.getElementById("security-button"));
- })();
-
-EOF
-
-"javascript <<EOF
-" inject_jquery = function(){
-" var s = document.createElement('script');
-" s.setAttribute('src', 'http://jquery.com/src/jquery-latest.js');
-" document.getElementsByTagName('body')[0].appendChild(s);
-" };
-"EOF
-"command! jquery js inject_jquery()
-
-javascript <<EOF
-delicious = function(){f='http://delicious.com/save?url='+encodeURIComponent(window.location.href)+'&title='+encodeURIComponent(document.title)+'&v=5&';a=function(){if(!window.open(f+'noui=1&jump=doclose','deliciousuiv5','location=yes,links=no,scrollbars=no,toolbar=no,width=550,height=550'))location.href=f+'jump=yes'};if(/Firefox/.test(navigator.userAgent)){setTimeout(a,0)}else{a()}};
-EOF
-command! delicious js delicious()
-
-" vim: ft=vimperator sw=2 sts=2 foldmethod=marker
View
1 .vimperatorrc

0 comments on commit 69f8432

Please sign in to comment.