Shougo / neosnippet.vim

neo-snippet plugin
Other
1.12k stars 108 forks source link

Neosnippet seems to not respect python indentation #467

Closed benmezger closed 5 years ago

benmezger commented 5 years ago

When having this snippet:

snippet debug
abbr ipdb or pdb
alias debug dbg pdb ipdb
  try:
      import ipdb
      ipdb.set_trace()
  except ImportError:
      import pdb
      pdb.set_trace()

And trying to use this in a buffer, this is what I get:

try:
    import ipdb
ipdb.set_trace()
except ImportError:
    import pdb
pdb.set_trace()

Why is Neosnippet not indenting the set_trace() line?

benmezger commented 5 years ago

Fixed! Use tabs instead of spaces and you are good to go.

Shougo commented 5 years ago

Yes. Please read the documentation.