@@ -9,11 +9,15 @@ if !pymode#default('g:pymode_init', 1)
99call pymode#breakpoint#init ()
1010endif
1111
12+ augroup pymode
13+
14+ au !
15+
1216command ! - buffer -nargs =1 PymodeVirtualenvcall pymode#virtualenv#activate (<args> )
1317
1418" Setup events for pymode
15- au pymode BufWritePre <buffer> call pymode#buffer_pre_write ()
16- au pymode BufWritePost <buffer> call pymode#buffer_post_write ()
19+ au BufWritePre <buffer> call pymode#buffer_pre_write ()
20+ au BufWritePost <buffer> call pymode#buffer_post_write ()
1721
1822" Run python code
1923if g: pymode_run
4347
4448" Remove unused whitespaces
4549if g: pymode_trim_whitespaces
46- au pymode BufWritePre <buffer> call pymode#trim_whitespaces ()
50+ au BufWritePre <buffer> call pymode#trim_whitespaces ()
4751endif
4852
4953" Custom options
@@ -70,19 +74,19 @@ if g:pymode_lint
7074let b: pymode_signs= []
7175
7276if g: pymode_lint_on_fly
73- au pymode InsertLeave <buffer> PymodeLint
77+ au ! InsertLeave <buffer> PymodeLint
7478endif
7579
7680if g: pymode_lint_message
77- au ! pymode CursorMoved <buffer>
78- au ! pymode CursorMoved <buffer> call pymode#lint#show_errormessage ()
81+ au ! CursorMoved <buffer>
82+ au ! CursorMoved <buffer> call pymode#lint#show_errormessage ()
7983endif
8084
8185" Disabled for current release
8286if g: pymode_lint_async
8387" let &l:updatetime = g:pymode_lint_async_updatetime
84- " au!pymode BufEnter <buffer> call pymode#lint#start()
85- " au!pymode BufLeave <buffer> call pymode#lint#stop()
88+ " au! BufEnter <buffer> call pymode#lint#start()
89+ " au! BufLeave <buffer> call pymode#lint#stop()
8690end
8791
8892endif
@@ -183,3 +187,5 @@ if g:pymode_rope
183187end
184188
185189end
190+
191+ augroup END