Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change show-hidden-files flag variable scope form buffer to script #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions autoload/renamer.vim
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@ function renamer#Start(needNewWindow, startLine, startDirectory) "{{{1
let save_sc = &sc
set report=10000 nosc

if !exists('b:RenamerShowHiddenEnabled')
if !exists('s:RenamerShowHiddenEnabled')
if exists('g:RenamerShowHidden') && g:RenamerShowHidden
let b:RenamerShowHiddenEnabled = 1
let s:RenamerShowHiddenEnabled = 1
else
let b:RenamerShowHiddenEnabled = 0
let s:RenamerShowHiddenEnabled = 0
endif
endif

Expand Down Expand Up @@ -146,7 +146,7 @@ function renamer#Start(needNewWindow, startLine, startDirectory) "{{{1
while i <= b:renamerPathDepth
let newPaths = []
for path in lastPaths
if b:RenamerShowHiddenEnabled
if s:RenamerShowHiddenEnabled
let newPaths += [ path . '/.[^.]*' ]
endif
let newPaths += [ path . '/*']
Expand Down Expand Up @@ -790,10 +790,10 @@ endfunction

function renamer#ToggleShowHidden() "{{{1
" Toggle whether to show hidden (dot) files/directories
if b:RenamerShowHiddenEnabled == 0
let b:RenamerShowHiddenEnabled = 1
if s:RenamerShowHiddenEnabled == 0
let s:RenamerShowHiddenEnabled = 1
else
let b:RenamerShowHiddenEnabled = 0
let s:RenamerShowHiddenEnabled = 0
endif
call renamer#Refresh()
endfunction
Expand Down