Andy Stewart
1ad55ae1eb
Fix type mismatch.
...
Introduced by attempt to workaround lack of support for default value in
getbufvar().
2014-01-09 17:57:19 +01:00
Andy Stewart
92abcce1ff
Stage and revert individual hunks.
2014-01-09 12:14:59 +01:00
Andy Stewart
7ce6309a01
Don't call getbufvar() with a default value.
...
Support for a default value in getbufvar() was introduced some time
after Vim 7.3.547 which is the current stable version in some package
repositories.
2014-01-09 10:05:49 +01:00
Andy Stewart
03ca0f8d93
Extract utility functions.
2014-01-08 09:55:54 +01:00
Andy Stewart
6369f5033b
Inline boolean logic.
2014-01-08 09:49:15 +01:00
Andy Stewart
2caf156c47
Eliminate redundant argument.
2014-01-08 09:47:43 +01:00
Andy Stewart
7919906105
Fix bug that processed buffers it shouldn't have.
...
All processing logic should be guarded by `utility#is_active()`.
2014-01-08 09:40:16 +01:00
darrenli
0218e08c9e
Fix GitGutter argument errors on save and toggle.
2014-01-07 21:40:34 +01:00
Andy Stewart
e88f9e16b4
Update gitignore.
2014-01-07 15:17:49 +01:00
Andy Stewart
d420a44536
Reduce duplicate work due to overlapping autocommands.
2014-01-07 15:02:27 +01:00
Andy Stewart
021a922083
Remove obsolete text.
2014-01-07 10:47:55 +01:00
Andy Stewart
88a2eb3626
Update FAQ.
2014-01-07 10:45:59 +01:00
Andy Stewart
c2cea84a7f
Remove Alternatives section.
...
I'm not going to spend time keeping it up to date so it'll just get more
and more obsolete.
2014-01-07 10:42:34 +01:00
Andy Stewart
fa582f7863
Only redraw when changing line highlighting.
2014-01-07 10:21:04 +01:00
Andy Stewart
b996dd3b53
Remove unnecessary precondition.
2014-01-06 17:11:19 +01:00
Andy Stewart
faa6aaf669
Minimise sign place/unplace calls to speed things up.
...
Profiling shows that `:sign place` and `:sign unplace` are slow despite
being native vimscript functions. This commit minimises the number of
such calls by only updating signs that have changed.
2014-01-06 17:05:01 +01:00
Andy Stewart
65b050ba2e
Fix unnecessary modified sign in modified-and-removed diff.
...
This bug didn't affect anything because the unnecessary sign was
overwritten by the correct sign.
2014-01-06 17:05:01 +01:00
Andy Stewart
c81d897d60
Reduce chance of dummy sign's id clobbering another.
2014-01-06 17:04:54 +01:00
Andy Stewart
cde54e3066
Simplify initialisation.
2014-01-06 11:47:42 +01:00
Andy Stewart
88623e3fec
Speed up snake-to-camel-case conversion.
2014-01-06 11:31:30 +01:00
Andy Stewart
a4f6acb731
Use buffer-local variables to store signs.
2014-01-06 11:22:34 +01:00
Andy Stewart
8a3d1cb88b
Remove obsolete code.
2014-01-06 10:43:53 +01:00
Andy Stewart
d3177cacd9
Remove unnecessary conditional.
2014-01-05 13:59:22 +01:00
Andy Stewart
702d27a84f
Autoload.
2013-12-17 11:03:52 +01:00
Bailey Ling
926aea86c1
Clear out hunks stats when file is not tracked.
2013-12-07 14:51:16 +00:00
Andy Stewart
f2e794b484
Always use realtime diff when buffer is modified.
...
This was motivated by Vim regaining focus into a buffer with unsaved
changes, and the realtime diff being replaced with an out of date disk
diff. With this commit the realtime diff will be run again.
2013-12-07 14:42:45 +00:00
Andy Stewart
6f760b077f
Fix typo.
2013-12-07 14:01:53 +00:00
Jakob Rath
cdfde92a15
Use correct line ending for realtime diff.
2013-12-07 14:00:07 +00:00
Suraj N. Kurapati
c5872cd042
support using POSIX sh(1) as set shell=/bin/sh
...
Use `cd` instead of `popd` because POSIX sh(1) does not have `pushd` and
also because this plugin did not pair its `pushd` with a `popd` anyway.
Use file redirection because POSIX sh(1) does not have anonymous pipes.
2013-09-25 10:42:13 -07:00
Andy Stewart
878c3422c9
Add note about Fish shell.
2013-08-22 10:47:41 +02:00
Bailey Ling
c44f4b8be6
Fix calculation of removed lines for hunk summary.
2013-08-21 11:30:10 +02:00
Wilson Y. Wong
6955f6dc91
Replace cd with pushd,
...
currently NOT working for windows
2013-08-19 19:22:05 -07:00
Andy Stewart
e07e6aa601
Move hunk summary function to diff utility section.
2013-08-19 17:55:46 +02:00
Bailey Ling
bdaff53497
add documentation for GitGutterGetHunkSummary.
2013-08-19 15:41:26 +00:00
Bailey Ling
8951f68795
extract updating hunk summary into another function.
2013-08-19 15:26:24 +00:00
Bailey Ling
ab58e070cf
introduce GitGutterGetHunkSummary for statusline integration.
2013-08-19 14:53:57 +00:00
Andy Stewart
1b5fe1bf9c
Update help text.
2013-08-19 15:25:57 +02:00
Andy Stewart
6e1e1dfe09
Update signs in realtime.
...
Thanks to @ashb for the help with this.
2013-08-19 15:21:32 +02:00
Andy Stewart
c896c9c7f6
Merge branch 'issue-84'
...
* issue-84:
Now working with shellslash
Fixed escaping
Escape shell commands on windows.
2013-08-19 10:34:13 +02:00
Wilson Y. Wong
e49faaea8f
Now working with shellslash
2013-08-13 22:16:02 -07:00
Wilson Y. Wong
fa6c08b841
Fixed escaping
2013-08-13 21:32:00 -07:00
Andy Stewart
da7900a809
Escape shell commands on windows.
2013-08-07 10:02:18 +02:00
Andy Stewart
15113259bb
Update when file modified externally.
2013-08-07 09:52:22 +02:00
Trevor Fitzgerald
ff031d022f
Prevent error message from showing when s:dummy_sign_id is not set
2013-04-24 19:57:33 -04:00
Andy Stewart
935184bd18
Add default mappings.
2013-04-17 11:23:11 +02:00
Andy Stewart
bcef63b7d5
Clarify FAQ.
2013-04-17 10:52:52 +02:00
Andy Stewart
01e7eb4e8d
Clarify that plugin works with saved buffers.
2013-04-17 10:51:45 +02:00
Andy Stewart
1a13951fc5
Simplify tradeoff between accuracy and speed.
...
If the plugin slows down your Vim too much, you can have it run less
often by setting `g:gitgutter_eager = 0`.
This replaces the former options `g:gitgutter_on_bufenter` and
`g:gitgutter_on_focusgained`.
2013-04-17 10:43:45 +02:00
Andy Stewart
b63d3c6f27
Revert "Use correct filename in auto commands."
...
That commit prevented gitgutter correctly activating on its first run.
This reverts commit 25d428c390 .
2013-04-15 10:24:37 +02:00
Andy Stewart
25d428c390
Use correct filename in auto commands.
...
This problem was revealed when using BufExplorer:
- Open vim with two files: `$ vim a.txt b.txt`
- Type `\\` to open BufExplorer.
- Press <enter> on `b.txt`.
- Vim shows `b.txt` as expected.
- Type `\\` to open BufExplorer.
- Press <enter> on `a.txt`.
- Expected: Vim shows `a.txt`.
Actual Vim shows `a.txt`, `b.txt`, `a.txt`.
I.e. the first invocation was fine but all subsequent invocations
rapidly flicked through <new file>, <old file>, <new file>.
2013-04-12 13:17:05 +02:00