Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge.

  • Loading branch information...
commit bc1737ebd0ea3a5f56d5b99768fc9a94a4e44f77 2 parents b01aaca + 7121f93
Steve Losh authored
6 .hgsubstate
@@ -3,8 +3,8 @@ b0da16490f168f68072973b45dbc27a74fb7b529 mercurial/histedit
3 3 4d95cb18a3b420154ef978c53de1d2e692f8343d mercurial/templates
4 4 d2bb7878622e4c16203acf1c92a0f4bc7ac58003 vim/bundle/AnsiEsc.vim
5 5 9895285042a2fd5691b2f6582aa979e4d1bdffea vim/bundle/ack
6   -cb09bd4000f0d0a971d15f93bc5f8b98a587915a vim/bundle/badwolf
7   -ed67c4908fa033eef6cdfacc8141750e99f1345b vim/bundle/clam
  6 +65adfb4b8907a83556b4d43234b115bacd958472 vim/bundle/badwolf
  7 +8533fffd9fbb690dfc8e334f91a10c72e35a6dce vim/bundle/clam
8 8 dc349bb7d30f713d770fc1fa0fe209e6aab82dc8 vim/bundle/commentary
9 9 3c6182371db8e8ede3789d21b52386569eda2208 vim/bundle/ctrlp
10 10 cff78c3ab4605d490e6be8d8af02f1e7efd25c95 vim/bundle/fugitive
@@ -20,7 +20,7 @@ f45b4529dd282393f2e08306ae161d77de0051a0 vim/bundle/orgmode
20 20 49ae47e66f51c92b0f467f9817d5d8745f627132 vim/bundle/python-mode
21 21 613eb1c81261adfa5dead315089c432ff6dbbc51 vim/bundle/repeat
22 22 61a7567a3cdd68cb65ceb3061071ce66d8110e65 vim/bundle/salt
23   -13c85f67a22848659f4365ae08567bb0d72bfc58 vim/bundle/slimv
  23 +cc25e468dce9703010efe691faa9764bd6577add vim/bundle/slimv
24 24 78ab4b3df24fa2753d3dfc1be75ed5a3df1565b8 vim/bundle/smartinput
25 25 c6197a10ace82e0fe0c08e5cf5c017b7069a978e vim/bundle/sparkup
26 26 3a2ab096c039516a8f43e6acd0264d8a81cd0544 vim/bundle/splice
3  dotcss/flickr.com.css
... ... @@ -1,3 +0,0 @@
1   -.spaceball {
2   - display: none !important;
3   -}
177 vim/bundle/watchit/plugin/watchit.vim
... ... @@ -0,0 +1,177 @@
  1 +" This file is all from
  2 +" http://vim.wikia.com/wiki/Have_Vim_check_automatically_if_the_file_has_changed_externally
  3 +
  4 +" If you are using a console version of Vim, or dealing
  5 +" with a file that changes externally (e.g. a web server log)
  6 +" then Vim does not always check to see if the file has been changed.
  7 +" The GUI version of Vim will check more often (for example on Focus change),
  8 +" and prompt you if you want to reload the file.
  9 +"
  10 +" There can be cases where you can be working away, and Vim does not
  11 +" realize the file has changed. This command will force Vim to check
  12 +" more often.
  13 +"
  14 +" Calling this command sets up autocommands that check to see if the
  15 +" current buffer has been modified outside of vim (using checktime)
  16 +" and, if it has, reload it for you.
  17 +"
  18 +" This check is done whenever any of the following events are triggered:
  19 +" * BufEnter
  20 +" * CursorMoved
  21 +" * CursorMovedI
  22 +" * CursorHold
  23 +" * CursorHoldI
  24 +"
  25 +" In other words, this check occurs whenever you enter a buffer, move the cursor,
  26 +" or just wait without doing anything for 'updatetime' milliseconds.
  27 +"
  28 +" Normally it will ask you if you want to load the file, even if you haven't made
  29 +" any changes in vim. This can get annoying, however, if you frequently need to reload
  30 +" the file, so if you would rather have it to reload the buffer *without*
  31 +" prompting you, add a bang (!) after the command (WatchForChanges!).
  32 +" This will set the autoread option for that buffer in addition to setting up the
  33 +" autocommands.
  34 +"
  35 +" If you want to turn *off* watching for the buffer, just call the command again while
  36 +" in the same buffer. Each time you call the command it will toggle between on and off.
  37 +"
  38 +" WatchForChanges sets autocommands that are triggered while in *any* buffer.
  39 +" If you want vim to only check for changes to that buffer while editing the buffer
  40 +" that is being watched, use WatchForChangesWhileInThisBuffer instead.
  41 +"
  42 +command! -bang WatchForChanges :call WatchForChanges(@%, {'toggle': 1, 'autoread': <bang>0})
  43 +command! -bang WatchForChangesWhileInThisBuffer :call WatchForChanges(@%, {'toggle': 1, 'autoread': <bang>0, 'while_in_this_buffer_only': 1})
  44 +command! -bang WatchForChangesAllFile :call WatchForChanges('*', {'toggle': 1, 'autoread': <bang>0})
  45 +
  46 +" WatchForChanges function
  47 +"
  48 +" This is used by the WatchForChanges* commands, but it can also be
  49 +" useful to call this from scripts. For example, if your script executes a
  50 +" long-running process, you can have your script run that long-running process
  51 +" in the background so that you can continue editing other files, redirects its
  52 +" output to a file, and open the file in another buffer that keeps reloading itself
  53 +" as more output from the long-running command becomes available.
  54 +"
  55 +" Arguments:
  56 +" * bufname: The name of the buffer/file to watch for changes.
  57 +" Use '*' to watch all files.
  58 +" * options (optional): A Dict object with any of the following keys:
  59 +" * autoread: If set to 1, causes autoread option to be turned on for the buffer in
  60 +" addition to setting up the autocommands.
  61 +" * toggle: If set to 1, causes this behavior to toggle between on and off.
  62 +" Mostly useful for mappings and commands. In scripts, you probably want to
  63 +" explicitly enable or disable it.
  64 +" * disable: If set to 1, turns off this behavior (removes the autocommand group).
  65 +" * while_in_this_buffer_only: If set to 0 (default), the events will be triggered no matter which
  66 +" buffer you are editing. (Only the specified buffer will be checked for changes,
  67 +" though, still.) If set to 1, the events will only be triggered while
  68 +" editing the specified buffer.
  69 +" * more_events: If set to 1 (the default), creates autocommands for the events
  70 +" listed above. Set to 0 to not create autocommands for CursorMoved, CursorMovedI,
  71 +" (Presumably, having too much going on for those events could slow things down,
  72 +" since they are triggered so frequently...)
  73 +function! WatchForChanges(bufname, ...)
  74 + " Figure out which options are in effect
  75 + if a:bufname == '*'
  76 + let id = 'WatchForChanges'.'AnyBuffer'
  77 + " If you try to do checktime *, you'll get E93: More than one match for * is given
  78 + let bufspec = ''
  79 + else
  80 + if bufnr(a:bufname) == -1
  81 + echoerr "Buffer " . a:bufname . " doesn't exist"
  82 + return
  83 + end
  84 + let id = 'WatchForChanges'.bufnr(a:bufname)
  85 + let bufspec = a:bufname
  86 + end
  87 +
  88 + if len(a:000) == 0
  89 + let options = {}
  90 + else
  91 + if type(a:1) == type({})
  92 + let options = a:1
  93 + else
  94 + echoerr "Argument must be a Dict"
  95 + end
  96 + end
  97 + let autoread = has_key(options, 'autoread') ? options['autoread'] : 0
  98 + let toggle = has_key(options, 'toggle') ? options['toggle'] : 0
  99 + let disable = has_key(options, 'disable') ? options['disable'] : 0
  100 + let more_events = has_key(options, 'more_events') ? options['more_events'] : 1
  101 + let while_in_this_buffer_only = has_key(options, 'while_in_this_buffer_only') ? options['while_in_this_buffer_only'] : 0
  102 +
  103 + if while_in_this_buffer_only
  104 + let event_bufspec = a:bufname
  105 + else
  106 + let event_bufspec = '*'
  107 + end
  108 +
  109 + let reg_saved = @"
  110 + "let autoread_saved = &autoread
  111 + let msg = "\n"
  112 +
  113 + " Check to see if the autocommand already exists
  114 + redir @"
  115 + silent! exec 'au '.id
  116 + redir END
  117 + let l:defined = (@" !~ 'E216: No such group or event:')
  118 +
  119 + " If not yet defined...
  120 + if !l:defined
  121 + if l:autoread
  122 + let msg = msg . 'Autoread enabled - '
  123 + if a:bufname == '*'
  124 + set autoread
  125 + else
  126 + setlocal autoread
  127 + end
  128 + end
  129 + silent! exec 'augroup '.id
  130 + if a:bufname != '*'
  131 + "exec "au BufDelete ".a:bufname . " :silent! au! ".id . " | silent! augroup! ".id
  132 + "exec "au BufDelete ".a:bufname . " :echomsg 'Removing autocommands for ".id."' | au! ".id . " | augroup! ".id
  133 + exec "au BufDelete ".a:bufname . " execute 'au! ".id."' | execute 'augroup! ".id."'"
  134 + end
  135 + exec "au BufEnter ".event_bufspec . " :checktime ".bufspec
  136 + exec "au CursorHold ".event_bufspec . " :checktime ".bufspec
  137 + exec "au CursorHoldI ".event_bufspec . " :checktime ".bufspec
  138 +
  139 + " The following events might slow things down so we provide a way to disable them...
  140 + " vim docs warn:
  141 + " Careful: Don't do anything that the user does
  142 + " not expect or that is slow.
  143 + if more_events
  144 + exec "au CursorMoved ".event_bufspec . " :checktime ".bufspec
  145 + exec "au CursorMovedI ".event_bufspec . " :checktime ".bufspec
  146 + end
  147 + augroup END
  148 + let msg = msg . 'Now watching ' . bufspec . ' for external updates...'
  149 + end
  150 +
  151 + " If they want to disable it, or it is defined and they want to toggle it,
  152 + if l:disable || (l:toggle && l:defined)
  153 + if l:autoread
  154 + let msg = msg . 'Autoread disabled - '
  155 + if a:bufname == '*'
  156 + set noautoread
  157 + else
  158 + setlocal noautoread
  159 + end
  160 + end
  161 + " Using an autogroup allows us to remove it easily with the following
  162 + " command. If we do not use an autogroup, we cannot remove this
  163 + " single :checktime command
  164 + " augroup! checkforupdates
  165 + silent! exec 'au! '.id
  166 + silent! exec 'augroup! '.id
  167 + let msg = msg . 'No longer watching ' . bufspec . ' for external updates.'
  168 + elseif l:defined
  169 + let msg = msg . 'Already watching ' . bufspec . ' for external updates'
  170 + end
  171 +
  172 + " echo msg
  173 + let @"=reg_saved
  174 +endfunction
  175 +
  176 +let autoreadargs={'autoread':1}
  177 +execute WatchForChanges("*",autoreadargs)
1  vim/custom-dictionary.utf-8.add
@@ -91,3 +91,4 @@ offline
91 91 bikeshed
92 92 bikesheds
93 93 inbox
  94 +iPhone
1  vim/vimrc
@@ -658,6 +658,7 @@ augroup ft_cram
658 658
659 659 au BufNewFile,BufRead *.t set filetype=cram
660 660 au Syntax cram setlocal foldlevel=1
  661 + au FileType cram nnoremap <buffer> <localleader>ee :e<cr>
661 662 augroup END
662 663
663 664 " }}}
2  weechat/alias.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# alias.conf -- WeeChat v0.3.8
  2 +# alias.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [cmd]
2  weechat/buffers.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# buffers.conf -- WeeChat v0.3.8
  2 +# buffers.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [color]
6 weechat/logger.conf
... ... @@ -1,14 +1,10 @@
1 1 #
2   -# logger.conf -- WeeChat v0.3.8
  2 +# logger.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [look]
6 6 backlog = 20
7 7
8   -[color]
9   -backlog_end = darkgray
10   -backlog_line = darkgray
11   -
12 8 [file]
13 9 auto_log = on
14 10 flush_delay = 120
2  weechat/plugins.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# plugins.conf -- WeeChat v0.3.8
  2 +# plugins.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [var]
2  weechat/relay.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# relay.conf -- WeeChat v0.3.8
  2 +# relay.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [look]
2  weechat/rmodifier.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# rmodifier.conf -- WeeChat v0.3.8
  2 +# rmodifier.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [look]
2  weechat/urlgrab.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# urlgrab.conf -- WeeChat v0.3.8
  2 +# urlgrab.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [color]
10 weechat/weechat.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# weechat.conf -- WeeChat v0.3.8
  2 +# weechat.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [debug]
@@ -58,22 +58,19 @@ mouse = off
58 58 mouse_timer_delay = 100
59 59 nickmode = on
60 60 nickmode_empty = off
61   -paste_bracketed = off
62   -paste_bracketed_timer_delay = 10
63 61 paste_max_lines = 3
64 62 prefix_action = " *"
65 63 prefix_align = right
66 64 prefix_align_max = 15
67 65 prefix_align_min = 0
68   -prefix_align_more = "+"
  66 +prefix_align_more = on
69 67 prefix_buffer_align = right
70 68 prefix_buffer_align_max = 0
71   -prefix_buffer_align_more = "+"
  69 +prefix_buffer_align_more = on
72 70 prefix_error = "=!="
73 71 prefix_join = "✔"
74 72 prefix_network = "--"
75 73 prefix_quit = "✘"
76   -prefix_same_nick = ""
77 74 prefix_suffix = "|"
78 75 read_marker = line
79 76 read_marker_always_show = on
@@ -169,7 +166,6 @@ max_visited_buffers = 50
169 166 [proxy]
170 167
171 168 [network]
172   -connection_timeout = 60
173 169 gnutls_ca_file = "%h/ssl/CAs.pem"
174 170 gnutls_handshake_timeout = 30
175 171
2  weechat/xfer.conf
... ... @@ -1,5 +1,5 @@
1 1 #
2   -# xfer.conf -- WeeChat v0.3.8
  2 +# xfer.conf -- weechat v0.3.7
3 3 #
4 4
5 5 [look]

0 comments on commit bc1737e

Please sign in to comment.
Something went wrong with that request. Please try again.