aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-07-23 10:49:22 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-07-23 10:49:35 +1200
commitcbbe15c1106b0bc351f8ba4495ad827e2c0fea77 (patch)
tree1ccee2fd0bb886bee94dda5d3adce048762a4577
parentAdd Vim mappings for normal {,} in diff buffers (diff)
parentBump VERSION (diff)
downloaddotfiles-cbbe15c1106b0bc351f8ba4495ad827e2c0fea77.tar.gz
dotfiles-cbbe15c1106b0bc351f8ba4495ad827e2c0fea77.zip
Merge branch 'hotfix/v1.37.2' into develop
* hotfix/v1.37.2: Bump VERSION Refactor Git commit cursor column with snip line Set gitconfig commit.verbose, clear commit.status Add push.followTags to Git configuration
-rw-r--r--VERSION4
-rw-r--r--git/gitconfig.mi53
-rw-r--r--vim/autoload/gitcommit.vim21
3 files changed, 15 insertions, 13 deletions
diff --git a/VERSION b/VERSION
index d172176f..2b5290b0 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
-tejr dotfiles v1.36.1
-Fri Jul 20 10:02:17 UTC 2018
+tejr dotfiles v1.37.2
+Sun Jul 22 22:14:02 UTC 2018
diff --git a/git/gitconfig.mi5 b/git/gitconfig.mi5
index cee0a759..edd7be77 100644
--- a/git/gitconfig.mi5
+++ b/git/gitconfig.mi5
@@ -14,7 +14,7 @@
ui = true
[commit]
- status = false
+ verbose = true
[core]
compression = 9
@@ -50,6 +50,7 @@
[push]
default = current
+ followTags = true
[sendemail]
confirm = compose
diff --git a/vim/autoload/gitcommit.vim b/vim/autoload/gitcommit.vim
index 56b35ba6..170cc2d0 100644
--- a/vim/autoload/gitcommit.vim
+++ b/vim/autoload/gitcommit.vim
@@ -1,18 +1,19 @@
" Choose the color column depending on non-comment line count
function! gitcommit#CursorColumn() abort
- " Last line number
- let l:ll = line('$')
-
" If we can find a line after the first that isn't a comment, we're
" composing the message
- if l:ll > 1
- for l:li in range(2, l:ll)
- if getline(l:li) !~# '^\s*#'
- return '+1'
- endif
- endfor
- endif
+ for l:num in range(1, line('$'))
+ if l:num == 1
+ continue
+ endif
+ let l:line = getline(l:num)
+ if strpart(l:line, 0, 1) !=# '#'
+ return '+1'
+ elseif l:line =~# '^# -\{24} >8 -\{24}$'
+ break
+ endif
+ endfor
" Otherwise, we're still composing our subject
return '51'