aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2019-06-10 16:15:29 +1200
committerTom Ryder <tom@sanctum.geek.nz>2019-06-10 16:15:29 +1200
commitfe1085f366291e132df1f53551cda03f62a5e7c1 (patch)
tree58adab4641c06748485433ec5d0fb649cce040cc
parentAdd bang to function declaration so it redefines (diff)
downloaddotfiles-fe1085f366291e132df1f53551cda03f62a5e7c1.tar.gz
dotfiles-fe1085f366291e132df1f53551cda03f62a5e7c1.zip
Limit scope of UTC function
-rw-r--r--vim/vimrc4
1 files changed, 2 insertions, 2 deletions
diff --git a/vim/vimrc b/vim/vimrc
index 5da1be46..dfa6c7ce 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -1185,12 +1185,12 @@ command PutDate
" getenv() and setenv() functions does not seem to fix it. It works fine in
" Debian GNU/Linux's packaged v8.0.x.
"
-function! UTC(command) abort
+function! s:UTC(command) abort
let tz = expand('$TZ')
let $TZ = 'UTC' | execute a:command | let $TZ = tz
endfunction
command -complete=command -nargs=1 UTC
- \ call UTC(<q-args>)
+ \ call s:UTC(<q-args>)
" Leader,d inserts the local date (RFC 2822)
nnoremap <Leader>d