I installed markdown-mode.el on emacs by using package-install. Then I created test.md file as a trial. Syntax hi-lighting apparently works fine in the text.
When I used "C-c C-c p" command in order to show markdown preview, I got following error message in backtrace buffer. Even if I saved test.md file in current directory, it still said "No such file or directory". The file is located in "~/workspace/daily_log/test.md."
I tried "M-x markdown-preview" instead of shortcut key. But it doesn't work,too.
Do I make a mistake about usage of markdown-mode? Any help would be appreciated. Thanks in advance.
Debugger entered--Lisp error: (file-error "Searching for program" "No such file or directory" "bash.exe")
call-process-region(1 36 "bash.exe" "/tmp/emacsAxnXZ9" #<buffer *markdown-output*> nil "-c" "markdown")
shell-command-on-region(1 36 "markdown" "*markdown-output*")
markdown("*markdown-output*")
markdown-preview()
call-interactively(markdown-preview nil nil)
command-execute(markdown-preview)
OS: Ubuntu 14.10
emacs: 24.4.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
markdown-mode: markdown-mode-20140914.1012/
Start impatient mode in the buffers you're interested to live preview: M-x impatient-mode . Open your browser to localhost:8080/imp. You'll see the list of buffers with the mode enabled. Click on one: you see live rendering of the buffer.
Install from atom (Recommended)Open atom editor, open Settings , click Install , then search markdown-preview-enhanced . After installation, you must restart atom to take effects. It is recommended to disable the builtin markdown-preview package after you install this package.
'markdown-mode' is a major mode for GNU Emacs which provides syntax highlighting and supporting commands for editing Markdown files. It provides keybindings and commands for inserting Markdown elements and to assist in calling 'markdown' to parse the source code or preview the document in a browser.
If you inspect the backtrace you'll see that this has nothing to do with your Markdown file.
markdown-preview
needs an external markdown
command that can generate HTML. It looks like whatever Markdown processor you are using is trying to call bash.exe
(not bash
) when converting your file.
markdown-command
, directly or indirectly causing it to call bash.exe
.Since you are on Ubuntu, a simple apt-get install markdown
should give you a decent Markdown that works with markdown-mode
's markdown-preview
function. After installing markdown
at the system level, make sure that Emacs has markdown-command
set to markdown
(the default value).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With