git-control.vim 435 Bytes
Newer Older
Moritz Sokoll's avatar
Moritz Sokoll committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
" Name: git-control
" Author: Moritz Sokoll
" Description: a git version conrol integration for vim

if exists('g:git_control_loaded')
	finish
endif

function! Git_Commit()
	let commit_message = input('commit message: ')
	if len(commit_message) > 1
		echoerr 'message must be at least one character long'
	else
		let stat = system("git commit -am '" . commit_message . "'")
		echo stat
	endif
endfunction

let g:git_control_loaded = 1