Uninstall Spacemacs - emacs

I'm trying to install Emacs via Homebrew. Having done this and aliased to my apps folder, I found that when I ran Emacs it came up Spacemacs. I did them remember the system had Spacemacs installed a few years ago. So, I uninstalled Emacs, removed the emacs folders. Now, Homebrew shows no installation of Emacs. However, when I run emacs in the terminal, I still get Spacemacs.
How do I completely remove Spacemacs so I can install "vanilla" Emacs?
I thought I'd look at where Spacemacs is installed and did a "whereis emacs", but nothing but the prompt was returned.

Remove or rename ~/emacs.d folder. Spacemacs is not a different emacs, it's a different way of initializing emacs. The initialization files are in ~/emacs.d.

I realised that Spacemacs was a layer of Emacs. I needed to delete the .spacemacs folder in my user directory. Once done Emacs showed up as vanilla.
To completely remove emacs, I also searched for "emacs" and it found some folders in various bin directories. Once all of this was removed my system was ready for a vanilla emacs installation.

First, check where your emacs loads its configurations. Probably from ~/.emacs.d.
Then, remove the folder or just rename it.
Finally, restart emacs
As of spacemacs, there is another file named .spacemacs, it usually dwells in your home folder. If you remove/rename ~/.emacs.d and do nothing about .spacemacs,emacs will not read .spacemacs.

Related

Emacs OSX 10.13 configuration issue

Recently I pass to Emacs org because is really convenient to me to write note there.
So I installed all packages I needed (principally ORG and EVIL) but I didn't understand how to setup everything.
I installed emacs from brew without using cask, I linked it, and I'm sure that I'm using the version that I installed (26.1).
So in my ~/ folder I have a .emacs file in which I set up evil mode, and I have a /.emacs.d/ in which I have a lot of file. The problem is: whatever I wrote in a ~/.emacs.d/init.el seems doesn't effect emacs.
So I said "whatever, I'm going on github and I installed some complete configurations and then I customized them myself". I tried to install these two configurations.
https://github.com/hrs/dotfiles
https://github.com/larstvei/dot-emacs?files=1
But for some reason, after doing exactly what they say on README.org
nothing happens.
In particular the second link, after install and open emacs said I need to have ~/.cask/.cask.el but I don't have it.
Advice?

Removing emacs prelude package

I installed prelude with curl before realizing that the OSX version of emacs is too old for prelude. Now I can't find any documentation on how to remove it and I'm hesitant to just start deleting files in my emacs folder that have the word 'prelude' in them. Is there a command to remove this?
The simplest way is to ask prelude where it is installed. Try this (even if emacs does not fully load all prelude):
ESC-x describe-variable prelude-dir
It will tell you where prelude is being loaded from.
I use Ubuntu 16.04 LTS and solved this problem this morning. Here what I do:
cd home/yourusrname
find .emacs and .emacs.d, if not. press Cril + h.
You will also see 2 files named like .emacs-pre-prelude.. and .emacs- pre-prelude.tgz .These are your .emacs and .emacs.d before you install prelude.
del .emacs and .emacs.d
rename .emacs-pre-prelude as .emacs
tar .emacs.d-pre-prelude.tgz find the .emacs.d in it and mv it to your /home/yourusrname/. restart emacs.

Emacs: where is better have the executable file?

After many changes on my Debian Jessie, when I launch the command emacs I receive an error libgnutls.so.26 : cannot open shared object file: No such file or directory.
If I launch instead the command emacs24 everything is allright.
I have emacs in /usr/local/bin
I have emacs24 in /usr/bin.
So, for now I created an alias to launch emacs24 as emacs, but i don't like and, for example, i have to change the git setting to open the default ide cause emacs is not availlable yet.
The question is where is the correct position of the command ? I have to change my PATH ?
Consider that libgnutls.so.26 is not installable from apt.
Thanks for any suggest or advice.
This is very strange, because a simple sudo dnf install emacs should suffice (I use fedora, so you probably use apt-get instead of dnf). Maybe it is best to just reinstall emacs (backup your .emacs to be safe) using apt-get? Anyhow, in fedora the emacs executable is located at /usr/bin/emacs (which is also the one used in the terminal when you use the emacs command).

Run latex within Emacs

I used to launch latex within Emacs on a .tex file by C-c C-c.
I just changed my machine, and need to reconfigure all. I have already installed texlive-full, and copied .emacs from the previous machine to the new machine.
When I open a .tex file under Emacs, launch C-c C-c, and then type LaTeX, it opens another buffer, named *tex-shell*, and looks like as so:
Could anyone tell me what happened?
I don't really now what happen, but it seem you want to use auctex:
sudo apt-get install auctex
and relaunch Emacs should solve your problem.

How do I byte-compile everything in my .emacs.d directory?

I have decided to check out Emacs, and I liked it very much. Now, I'm using the Emacs Starter Kit, which sort of provides better defaults and some nice customizations to default install of Emacs.
I have customized it a little, added some stuff like yasnippet, color-themes, unbound, and other stuff. I've set up a github repository where I keep all of the customizations so I can access them from multiple places or in case something goes bad and I lose my .emacs.d directory.
All of this is very nice, but there is a problem: Emacs takes about 1-2 seconds to load. AFAIK I can compile individual .el files with M-x byte-compile-file to .elc, and it works. But there are a lot of .el files, and I wonder if there is a way to compile them all with a simple command or something, to speed up the loading of Emacs. My Emacs is not always open, and I open and close it quite frequently, especially after I've set it up as a default editor for edit command in Total Commander to get used to it faster (yeah, windows xp here).
My Emacs version is 22.3. And yes, the default Emacs installation without any customizations fires up instantly.
I am not sure which version is preferred when loading, the .el or compiled .elc one by the way O.o
So, is there an elisp command or Emacs command line switch to make Emacs byte-compile everything in .emacs.d directory?
C-u 0 M-x byte-recompile-directory
will compile all the .el files in the directory and in all subdirectories below.
The C-u 0 part is to make it not ask about every .el file that does not have a .elc counterpart.
To automatically byte compile everything that needs byte compiling each time I start emacs, I put the following after my changes to load-path at the top of my .emacs file:
(byte-recompile-directory (expand-file-name "~/.emacs.d") 0)
Surprisingly, it doesn't add much to my startup time (unless something needs to be compiled).
To speed up my emacs, I first identified the slow parts using profile-dotemacs.el and then replaced them with autoloads.
You can use the --batch flag to recompile from the command line.
To recompile all, do
emacs --batch --eval '(byte-recompile-directory "~/.emacs.d")'
or to recompile a single file as from a Makefile,
emacs --batch --eval '(byte-compile-file "your-elisp-file.el")'
This is swaying a bit from the question, but to solve the problem of loading slowly you can use the new daemon feature in Emacs 23.
"If you have a lot of support packages,
emacs startup can be a bit slow.
However, emacs 23 brings emacs
--daemon, which enables you to start emacs in the background (for example
when you log in). You can instantly
pop up new emacs windows (frames) with
emacsclient. Of course, you could
already have an emacs 'server' in
older versions, but being able to
start it in the background makes this
a much nicer solution"
From http://emacs-fu.blogspot.com/2009/07/emacs-23-is-very-near.html
The command I use is M-x byte-force-recompile RET, it then asks the directory so, for example, I give it ~/.emacs.d/elpa/. It then recompiles everything in there, usually no need to delete .elc files first or mess with it in other ways.
For my using spacemacs, the command is spacemacs/recompile-elpa. The command byte-recompile-directory does not compile any file.