How to install emacs colortheme

emacs

I found this website and downloaded the color-theme files.
It says:

Put the file color-theme.el and the
folder “themes” (with the files
color-theme-example.el and
color-theme-library.el) in a directory
on your LoadPath.

and then I checked the load path website, which says:

To add a single directory to the load-path:

(add-to-list 'load-path "~/.emacs.d/site-lisp/")

My question is, where do I type this line?
If I do M-x and then type, it complains add-to-list[No match].

By the way, I am using Emacs 23.2(9.0) on Mac, a GUI version.
For the text version on terminal, I use black background seems fine, except the blue is too dark on black

Best Answer

An answer for newbs like me!

In Emacs 24.5.1, on mac or linux the following will work.

The following command will create a folder called themes inside your .emacs.d folder (assuming one does not already exist)

mkdir ~/.emacs.d/themes/

Now tell emacs that you have installed a themes folder. In emacs open your .emacs file, by typing the following:

C-x C-f ;;;this opens a new .emacs file or creates one if it doesn't exist

Add the following line to your .emacs file:

(add-to-list 'custom-theme-load-path "~/.emacs.d/themes/") 

Now copy your theme's '.el' file to your .emacs.d/themes/ directory. A good place to find custom themes is here: emacsthemes.com

Now load your custom theme by typing the following:

M-x customize-themes ;;;now press return

Your newly installed themes should appear on the list like so:

emacs *Custom Themes* buffer

Move your cursor to within the '[ ]' and press return to select that theme.

Enjoy emacs!

Related Topic