Emacs auto-complete for installed library via quicklisp? - emacs

I'm using Emacs 24.3 + SBCL + Slime + Quicklisp.
Emacs auto-complete works well in slime.
But, I usaully write lisp code in .lisp file where I can't load cl library because .lisp file is not REPL as you know.
How can I do auto-complete without loading lisp file installed via quicklisp?

I solved by myself.
Just (ql:quickload :wherever) Then write a lisp code in .lisp file.
Now semantic will work. But, It depends on semantic configuration.
In my case, .el file didn't support auto-complete even if I loaded a library.

Related

Common Lisp auto completion in emacs

Update
Apparently, the auto-complete package is not the culprit.
Emacs fails to download melpa archive.
A quick google search indicates that this is a reappearing problem both on windows and unix machines.
As there are already threads concerning failed to download 'melpa' archive (none of which helped unfortunately) this thread may or may not be closed.
Inital Question
I'm trying to set up emacs for Common Lisp.
I installed sbcl and the slime package.
Some time ago I used to have auto completion for Common Lisp keywords in emacs such that - while typing - it suggested a word via a greyed out completion (TAB for acceptance) or via drop down or both. (I can't remember exactly.)
I'm struggling to get this working again.
At https://github.com/purcell/ac-slime it is suggested to first install auto-complete but when I type package-list-packages there is no such package. (But there are plenty named auto-complete-*).
(I set up Melpa with:
(require 'package)
(add-to-list 'package-archives
'("melpa" . "http://melpa.org/packages/")))
The provided link http://cx4a.org/software/auto-complete/ is dead as well.M-x install-package [RET] auto-complete [RET] also fails. Emacs says: [No match]
So my question is:
If there is no auto-complete package anymore, what is a good way to set up Common Lisp auto completion in emacs in the way mentioned above (greyed out word or dropdown)?
The current home-page for auto-complete is https://github.com/auto-complete/auto-complete
Installing it should be enough to allow you to use ac-slime (there is also a completion version using company).
Here is how I got it to work.
Download the .ZIP archive with repository here.
Unzip
Run M-x package-install-file
On the prompt, specify the path to the downloaded repository and the file named auto-complete.el.
Make sure that installation returns something along the lines of "Successful"
Add this line to your Emacs initialization file (.emacs):
(ac-config-default)
To auto-complete in SLIME, follow similar step to install ac-slime (requires SLIME and Auto-complete)
P.S. There is another package called company (stands for Complete Anything), which is quite good as an alternative. I am trying it out now. Getting it to work was very simple.

Emacs can't load swi-prolog with default prolog-mode?

My Gnu Emacs 24.4 on Win 8 can't seem to work with it's default prolog mode. I have the latest version of SWI Prolog.
When I load Gnu Emacs and type in Mx prolog-mode, the syntax gets highlighted. However, I am not able to compile the rules, or do anything with them. When I try to run prolog from inside Emacs using Cc RET, it says "Searching for program: no such file or directory, prolog".
The error message tells you that Emacs couldn't find any executable with name prolog in load-path. So presumably the problem is that you haven't put your installation of SWI-Prolog into your $PATH.
An alternative to setting $PATH in your environment (or load-path in your ~/.emacs) is to set prolog-program-name in your ~/.emacs.
You wouldn't happen to be taking cmsc330 would you? Anyway if your not wedded to Emacs, Eclipse has a plugin for SWI and it autofills as well. I would just use eclipse.

Emacs 24.3 cannot find package (key-chord) during startup

I have Emacs 24.3 running on Raspbian. I'm kind of enjoying running Emacs on Linux - seems to be a beter fit than on Windows. I installed the very useful key-chord package using the usual package functions. This results in a directory in ~\.emacs.d\elpa\key-chord-20080915.2156.
Then I inserted the following in my init file:
(require 'key-chord)
(key-chord-mode 1)
This kicks out the following error:
File error: Cannot open load file, key-chord
However, if I hit M-x I can find all the key-chord functions and run key-chord mode and associated bits and pieces. What am I doing wrong...?
Emacs loads the installed packages after evaluating your init file. If you need your packages in your init file, you can use (package-initialize) to manually initialize the packages.
The reason you see some or all key-chord functions is that these functions are "autoloaded". You don't need a require to use these functions; in fact, the package is automatically loaded when you use such a function.

How to fix this error? emacs.d/starter-kit.el: `flet' is an obsolete macro (as of 24.3); use either `cl-flet' or `cl-letf'

I just installed the emacs-starter-kit into Debian Wheezy with the emacs-snapshot. I am getting and error:
Loading /home/felixdz/.emacs.d/starter-kit-registers.el (source)...done
loaded /home/felixdz/.emacs.d/starter-kit-registers.el
../.emacs.d/starter-kit.el: `flet' is an obsolete macro (as of 24.3); use either `cl-flet' or `cl-letf'.
Loading /home/felixdz/.emacs.d/starter-kit.el (source)...done
loaded /home/felixdz/.emacs.d/starter-kit.el
For information about GNU Emacs and the GNU system, type C-h C-a.
Package assoc is obsolete!
How do I fix this error? I am a completer beginner with Emacs.
It's not really an error, but a warning.
And it's not aimed at you but at the package maintainers of
some package that you load from the starter kit.
The point is that there's a vanilla Emacs 24.3, which doesn't give warnings,
and then there are various libraries written for earlier versions of Emacs
that you're using for Emacs 24.3. Hence the warnings.
It will still work for now, but probably when the next Emacs comes out
the assoc package will produce an error instead of a warning like now.
You can choose now if you want the emacs-starter-kit or vanilla Emacs
or something else. I learned my way from vanilla Emacs, doing the customizations
myself.

Using two emacs (Cocoa emacs and Aquamacs) at the same time

I happen to have two emacs on my Mac because of clojure setup.
The problem is that Cocoa emacs and Aquamacs uses the same ~/.emacs.d, but the ELPA of Cocoa emacs and that of Aquamacs are not compatible so that some files are overwritten and not usable for both of them.
Is there any way to tell Aquamacs not to use ~/.emacs.d for ELPA? I mean, can I change the default ELPA directory other than ~/.emacs.d ?
I use Aquamacs Starter Kt, but it seems that the ~/.emacs directory is used in init.el.
(unless (file-directory-p "~/.emacs.d/elpa")
(make-directory "~/.emacs.d/elpa" t))
I am not familiar with ELPA, but if aquamacs and carbon emacs are using different copies of package.el, you could try changing the definition of package-user-dir in one of them. In general I have found that using two different emacses on one machine is a recipe for baldness.