Jas
Jas

Reputation: 15103

No markdown-mode package available in emacs (spacemacs)

in https://jblevins.org/projects/markdown-mode/ at the installation section it says:

The recommended way to install markdown-mode is to install the package from MELPA Stable using package.el. First, configure package.el and the MELPA Stable repository by adding the following to your .emacs, init.el, or equivalent startup file:

(require 'package) (add-to-list 'package-archives
             '("melpa-stable" . "https://stable.melpa.org/packages/")) (package-initialize)

So I added it to my init.el, then restarted spacemacs, then I hit M-x and package-install but i don't see any markdown-mode package, am I doing anything wrong?

enter image description here

Here is my init.el:

;;; init.el --- Spacemacs Initialization File
;;
;; Copyright (c) 2012-2017 Sylvain Benner & Contributors
;;
;; Author: Sylvain Benner <[email protected]>
;; URL: https://github.com/syl20bnr/spacemacs
;;
;; This file is not part of GNU Emacs.
;;
;;; License: GPLv3

;; Without this comment emacs25 adds (package-initialize) here
;; (package-initialize)

;; Increase gc-cons-threshold, depending on your system you may set it back to a
;; lower value in your dotfile (function `dotspacemacs/user-config')
(setq gc-cons-threshold 100000000)

(defconst spacemacs-version         "0.200.13" "Spacemacs version.")
(defconst spacemacs-emacs-min-version   "24.4" "Minimal version of Emacs.")

(if (not (version<= spacemacs-emacs-min-version emacs-version))
    (error (concat "Your version of Emacs (%s) is too old. "
                   "Spacemacs requires Emacs version %s or above.")
           emacs-version spacemacs-emacs-min-version)
  (load-file (concat (file-name-directory load-file-name)
                     "core/core-load-paths.el"))
  (require 'core-spacemacs)
  (spacemacs/init)
  (configuration-layer/sync)
  (spacemacs-buffer/display-startup-note)
  (spacemacs/setup-startup-hook)
  (require 'server)
  (unless (server-running-p) (server-start)))

;; (org-babel-load-file "~/.emacs.d/configuration.org")

;; Additional...
(require 'package)
(add-to-list 'package-archives
             '("melpa-stable" . "https://stable.melpa.org/packages/"))
(package-initialize)

Upvotes: 0

Views: 655

Answers (2)

EFLS
EFLS

Reputation: 381

Remember that spacemacs has it's own way of managing packages. I'd recommend simply loading the markdown layer, which should take care of installing the required packages

Simply add markdown to the list of layers your .spacemacs:

dotspacemacs-configuration-layers
'(
  ;; ...
  ;; other layers
  markdown
 )

Upvotes: 1

Jas
Jas

Reputation: 15103

Ended up with this (after asking for help somewhere else, documentation was not helpful) as it turns out it's one of the below options, either one of:

M-x -> customize-option -> org-export-backends checkbox on md

OR

Add to (defun dotspacemacs/user-config () (at file ~/.spacemacs)

which can be accessed by SPC f e d

Then adding the following into user-config function:

(setq org-export-backends '(ascii beamer html latex md))

I really wonder why I got -6 it was not easy to find this especially as a newbie in emacs world.

Upvotes: 0

Related Questions