craigemery/dotFiles — comment on commit 4f58343ccaa5d275a955b78140a6bb94c225807c
File:  line 0
By craigemery:

I see the problem, yes, I was thinking thought that the default behaviour
wouldn't be to stop at $HOME.

So I'd propose:

diff --git a/vim/plugin/autotag.vim b/vim/plugin/autotag.vim
index 082cb0b..b17f430 100755
--- a/vim/plugin/autotag.vim
+++ b/vim/plugin/autotag.vim
@@ -41,7 +41,7 @@ vim_global_defaults = dict(maxTagsFileSize = 1024*1024*7,
CtagsCmd = "ctags",
TagsFile = "tags",
Disabled = 0,
- StopAt = 0)
+ StopAt = "")

# Just in case the ViM build you're using doesn't have subprocess
if sys.version < '2.4':
@@ -119,7 +119,7 @@ class AutoTag:
self.count = 0
self.logger = logger
self.home_dir = os.environ.get("HOME", None)
- self.stop_at = not bool(vim_global("StopAt")) or self.home_dir
+ self.stop_at = vim_global("StopAt")

def __log(self, *args, **kwargs):
return self.logger.log(self.verbosity, *args, **kwargs)

Craig

On 1 February 2012 16:11, Manpreet Singh <
reply@reply.github.com
> wrote:

> Unless I am misunderstanging the use of autotagStopAt, the code to set it
> should be.
>
> ```python
> if vim_global("StopAt"):
> self.stop_at = vim_global("StopAt")
> else:
> self.stop_at = self.home_dir
> ```
>
> Currently it just gets set to True if user hasn't set it.
>
> ---
> Reply to this email directly or view it on GitHub:
>
> https://github.com/craigemery/dotFiles/commit/4f58343ccaa5d275a955b78140a6bb94c225807c#commitcomment-922871
>