1

So what I have tried is to first install the package by using MELPA:

M-x package-install RET mmm-jinja2

I looked up where the package have been installed and found it to be at "~/.emacs.d/elpa/mmm-jinja2-0.1/mmm-jinja2.el" so now I am trying to load it in my ~/.emacs file, I do this by simply following the instructions on their GitHub page, only changing where my package is stored

(load "~/.emacs.d/elpa/mmm-jinja2-0.1/mmm-jinja2.el")
(add-to-list 'auto-mode-alist '("\\.jinja2\\'" . html-mode))
(mmm-add-mode-ext-class 'html-mode "\\.jinja2\\'" 'jinja2)

Next I restart emacs and it load the init-file file just fine, but still I am unable to use the package, it can not be found among my modes. I have made sure to have both mmm-mode and python-mode installed and working also, so it probably is not because of a dependency.

Where should I start to debug in order to find where the problem may be?

  • Do you have mmm-mode installed? – Melioratus Jun 28 '18 at 0:32
  • Yes I have, have tried it also and it seem to be working fine – Salviati Jun 28 '18 at 0:46
  • 1
    After googling a bit, I'm wondering if the issue may be with assigning mode to html-mode instead of python-mode. Before today, I've never heard of jinja2 before so that's my best guess. – Melioratus Jun 28 '18 at 2:15
  • I tried it but sorry to say it did not work. The reason (I believe) he assign html-mode is when using the jinja2-mode I should also be able to use html-mode together with the jinja2-mode. So when coding I use an .html file (there off html-mode), than python-mode (to be used when coding python in the .html file to get color encoding and so on) and also the jinja2-mode, all at the same time. But this is just my guess, to be honest I do not know – Salviati Jun 28 '18 at 2:42

Your Answer

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

Browse other questions tagged or ask your own question.