Installing Emacs on Windows 95/98/2K/NT/ME/XP/Vista
People have successfully installed emacs
(version 21.3) on Windows 95, 98, 2K, NT, ME, XP, and Vista using the
instructions below. [I have not tried Vista myself yet with these
instructions, but Sherrie used them
successfully.]
Warning: This page is being
maintained mainly for my students. Use these instructions at your own
risk if you are not a student taking one of my classes. There is no
warranty in any form or shape whatsoever! There is no guaranty that
these instructions are up-to-date although I will update them for my
students on an on-going basis. With that understanding, you may
continue with the rest of this page if you choose to accept these
terms.
Emacs version 22.2: Read
this if you want to install a newer
version (22.2) instead of 21.3.
Emacs version 21.3: So, let's
get to it. The instructions below were last updated in September
2005, but still valid - emacs is a very stable system and we
would not expect it to change much at all.
Follow these steps to download and install Emacs on your windows
machine. There is no room for creativity
here; you must follow the directions exactly - every single
word.!.
- Pick the drive and a folder in which you want to install Emacs.
I'll assume that it is C:\emacs, but you can choose a
different one. If you choose a different
drive or a different folder, you'll need to adapt the directions below
accordingly.
- Create an empty folder
C:\emacs. At the DOS prompt in
the C: drive, type mkdir emacs.
- Download
emacs-21.3-bin-i386.tar.gz to C:\emacs\emacs-21.3-bin-i386.tar.gz by
right-clicking on the link and using Save
Link As... or Save Target
As.... Or simply clicking on it would work as well here.
It is about 13.2 megabytes. Make sure the entire file was downloaded
without any network errors. The browser will save the file using the
name that appears in the underlined link. (In some Windows XP
machines it is known to use emacs-21.3-bin-i386.tar.tar
instead as it downloads it. If that happens, change the name back to
emacs-21.3-bin-i386.tar.gz before you continue. Note that
your Windows Explorer may actually show
emacs-21.3-bin-i386.tar by hiding that file extension
(.gz) in which case you can actually change the settings so
that it displays the extension. Try the Tools menu in your
Windows Explorer and Folder Options. Then, the View
menu and uncheck the Hide extensions for known file types and
OK to keep the change.)
At this point, you should have one file named
emacs-21.3-bin-i386.tar.gz
of about 13.2 megabytes in the
C:\emacs folder.
Check to be sure.
- Click on that file using Windows Explorer to extract files
from that archived file. Your extracted files should go into C:\emacs folder. Assuming that you
already have a program installed in your machine that knows how to
unpack the zipped file, you can click on it to extract the files. In
my case I have PowerArchiver
installed on my machine and that gets invoked automatically when I
click on a zip file. PowerArchiver
is available free. Chances are that you already have this program or
something that works like that installed on your Windows machine. If
there is no program that knows how to unpack the zip file, install
PowerArchiver before you continue.
Once extraction is done, you will see a folder named emacs-21.3 under C:\emacs. Under emacs-21.3, you will see other
folders including bin, etc, info, etc. At this point, you have
downloaded and placed the files in the right places.
- Next, you will download a file that will customize your emacs a
little so that it makes your editor screen easier to read with colors
recognizing some standard file types that you will be editing, e.g., a
Java program file. Download _emacs.txt to
C:\emacs\_emacs.txt by
right-clicking on the link. Yes, the underscore character is part of
the name. Use Save Link As...
or Save Target As... Now,
rename it to _emacs with
Windows Explorer so that there is no .txt extension (or any other
extension) as part of the file name. Remember that your Windows
Explorer may not show the extension (.txt) even if it is
actually there if your settings hid the extension? Change the
settings to unhide the extension and remove it.
- Depending on the operating system that you use, choose one of the
following paths:
- 95 or 98: edit your autoexec.bat file and add
this line:
set HOME=C:\emacs\
You will probably find autoexec.bat on your
C: drive. Edit it with Notepad. You can't edit
it by clicking on it. Start Notepad and then open it
with the File menu.
- 2K, ME, or XP: add HOME as an environment variable.
Follow Start > Settings > Control Panel
> System. Then select Advanced followed by Environment Variables. Then, add HOME as a user variable with
its value C:\emacs\.
- NT: It works like 98 with the autoexec.bat file. I suspect it would
work like 2K as well, but I have not tried it that way
myself.
- Restart your machine.
- At this point, you might want to create an icon on your desktop
for the Emacs that you just installed. Go to the
C:\emacs\emacs-21.3\bin folder
using Windows Explorer. There you will find a file named runemacs.exe. Create a shortcut
to the desktop so that you can use it to run Emacs from the
desktop. Now, you should be in
business! If it doesn't work, you made
a mistake in one of the steps above. Double and triple check.
- After you create the shortcut, you might want to change the
default 'Start in' folder.
Change it to whatever you like through the Properties menu of the icon.
- If you want to clean up a little, you may delete emacs-21.3-bin-i386.tar.gz at this
point. You still need _emacs
and emacs-21.3 in the C:\emacs folder though.
- To learn how to use Emacs, try Emacs
Tutorial that you can find under the Help menu in the Emacs window. Or,
if you want a simpler version, try this
tutorial that I wrote.
- [Only optionally because I
wanted this to be a simple page that shows just enough to get
started.] To learn how to customize Emacs or simply to see more
help on it, try Emacs
Help Guide by Hemant Kumar. (That site will talk about .emacs file, which is the unix/linux
version of _emacs.) I am sure
there are many other sources of information on emacs out there, but
Paul Fiorillo found this site.
Maintained by Art Lee
(alee at cmc dot edu).