Question

I have installed yasnippet 0.8 from elpa on emacs 24 and I want to write a snippet that inserts this text into a LaTeX document (using AUCTeX):

\\

\vspace{10pt}

So I have this snippet:

# -*- mode: snippet -*-
# name: para
# key: para
# binding: direct-keybinding
# expand-env: ((some-var some-value))
# type: command
# --
\\\\

\\vspace{10pt}

but when I type para<TAB> all that happens is that the text para is removed. What am I doing wrong?

Was it helpful?

Solution

You're using some defaults that shouldn't be there. Change it to:

# -*- mode: snippet -*-
# name: para
# key: para
# --
\\\\

\\vspace{10pt}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top