0

I want to use yasnippet to create a generic template for my org-mode files including latex export classe (letters, memos, articles, etc...)

It's not that complicated, but I would like Yasnippet to offer me to choose from the list of latex classes I have configured myself with (add-to-list 'org-latex-classes ...).

Therefore I introduced in my snippet the following line:

#+LATEX_CLASS: ${2:$$$(yas-choose-value '(org-latex-class))}

However, it seems that the variable is not recognized as a stringp :

yas--move-to-field: Wrong type argument: stringp, (sequencep org-latex-class)

Is there a way in elisp to convert sequencep to stringp ? Could it solve the problem ?

1

You need a list with the class names only:

#+LATEX_CLASS: ${2:$$(yas-choose-value (mapcar #'car org-latex-classes))}
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.