Skip to content

Commit

Permalink
Bug fix: Disable :argglobal/:argument commands just like :args
Browse files Browse the repository at this point in the history
  • Loading branch information
xolox committed Apr 18, 2013
1 parent cacf986 commit e365e75
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions autoload/xolox/session.vim
@@ -1,9 +1,9 @@
" Vim script
" Author: Peter Odding
" Last Change: April 17, 2013
" Last Change: April 18, 2013
" URL: http://peterodding.com/code/vim/session/

let g:xolox#session#version = '1.5.1'
let g:xolox#session#version = '1.5.2'

" Public API for session persistence. {{{1

Expand Down Expand Up @@ -137,6 +137,11 @@ function! s:state_filter(line)
" given, thereby breaking the session that the user was expecting to
" get... I consider this to be a bug in :mksession, but anyway :-).
return '" ' . a:line
elseif a:line =~ '^\(argglobal\|\dargu\)$'
" Because we disabled the :args command above we cause a potential error
" when :mksession adds corresponding :argglobal and/or :argument commands
" to the session script.
return '" ' . a:line
else
return a:line
endif
Expand Down

0 comments on commit e365e75

Please sign in to comment.