Since I would like to use accurev from emacs, I tried using this .el module:
https://github.com/shellbj/vc-accurev. However, I get the following error on both emacs 23.4.1 and 24.3:
Debugger entered--Lisp error: (void-function defclass)
(defclass vc-accurev-object nil ((node-name :initform ... :type symbol :allocation :class :documentation "XML node name")) :abstract t)
eval-current-buffer()
call-interactively(eval-current-buffer t nil)
execute-extended-command(nil)
call-interactively(execute-extended-command nil nil)
I'm running native emacs on windows 7. Can someone kindly help me make this run so I can manipulate accurev from emacs? I'm also curious about learning how to use EIEIO (which is the package that apparently implements this defclass extension). Bing/Google searching did not reveal a require statement.
Thanks
Siegfried
Related
When I start emacs I get the error
Debugger entered--Lisp error: (wrong-type-argument stringp nil)
string-match("cmd\\.exe" nil)
(if (string-match "cmd\\.exe" tramp-encoding-shell) "/c" "-c")
eval((if (string-match "cmd\\.exe" tramp-encoding-shell) "/c" "-c"))
this appears to occur when loading the magit pack
eval-buffer(#<buffer *load*-330059> nil "c:/cygwin64/home/johnstonk/.emacs.d/emacs-live/packs/stable/git-pack/lib/magit/magit.el" nil t) ; Reading at buffer position 3100
I confirmed this occurs with a fresh git clone of emacs-live.
I tried removing the magit pack from loading in the live init file but I got the same error again when it loaded the clojure pack. Looks like a nil string error in tramp.
Does anyone know why?
Going through and loading the source code for tramp-sh.el I got the same (wrong-type-argument stringp nil) on the first line (require 'tramp)
So I loaded tramp.el (version 22.1) and got to the section
(defcustom tramp-encoding-shell
(if (memq system-type '(windows-nt))
(getenv "COMSPEC")...
I noticed that this system-type is getting set to windows-nt (As it should, I'm on windows7) but (getenv "COMSPEC") is returning nil. From what I googled elsewhere this COMSPEC environment variable is expected to exist on windows machines and point to the shell. Tramp uses the tramp-encoding-shell var for encoding and decoding commands on the local machine such as "~" -- at least according to tramps comments.
COMSPEC didn't exist as an system environment variable for me so I created it and pointed it to cmd.exe C:\Windows\System32\cmd.exe That fixed it for me.
Note don't set COMSPEC to powershell, I tried that first but got a nasty memory leak when I tried to use lein (keeps trying to create a server, fails, and tries again but doesn't clean up previous thread).
When I open an HTML file with emacs (and nXhtml,) I get the following error from flymake:
Error (flymake): Flymake: Failed to launch syntax check process 'xml'
with args (val
/home/ABC/Downloads/capitals_flymake.html):
Searching for program: no such file or directory, xml. Flymake will be
switched OFF
I assume this means that I need to have a program installed that can be run at the command line with xml. However, I have not been able to find out what this program is in the documentation.
I am also currently using the following gist (with a modification suggested by one of the commenters to change equal to >=) to disable the Mumamo buffer filenames warning in my .emacs:
;; Workaround the annoying warnings:
;; Warning (mumamo-per-buffer-local-vars):
;; Already 'permanent-local t: buffer-file-name
(when
(and
(>= emacs-major-version 24)
(>= emacs-minor-version 2))
(eval-after-load "mumamo"
'(setq mumamo-per-buffer-local-vars
(delq 'buffer-file-name mumamo-per-buffer-local-vars))))
But, I am not sure if that is relevant.
How can I get flymake to work with nXhtml? I am currently on GNU Emacs 24.3.1.
I have this in my .emacs for live validating of XML and HTML, see if this would help.
(defun flymake-xml-init ()
(list "xmllint"
(list "--valid"
(flymake-init-create-temp-buffer-copy
'flymake-create-temp-inplace))))
(defun flymake-html-init ()
(let* ((temp-file (flymake-init-create-temp-buffer-copy
'flymake-create-temp-inplace))
(local-file (file-relative-name
temp-file
(file-name-directory buffer-file-name))))
(list "tidy" (list local-file))))
(add-to-list 'flymake-allowed-file-name-masks
'("\\.html$" flymake-html-init))
Also, re xml executable: it might be this one http://packages.ubuntu.com/quantal/amd64/xml2/filelist from how it looks... also you can try apt-file /usr/bin/xml (I'm not sure if apt-file is installed by default, if not, then apt-get install apt-file). Also, maybe this would help: http://www.emacswiki.org/emacs/FlyMake . I couldn't find any setting particular to nXhtml that does something to flymake.
The default program that flymake is told to use (xml) isn't installed on your computer, or its location isn't in your path. You need to tell flymake to use a different syntax checker just like #wvxvw said (see their answer for the code).
However, when you change the syntax checker, you may also need to tell flymake how that new checker will output error messages or else flymake won't know how to read the checker's output.
If your new checker program has an exit code other than 0 (which normally indicates an error) AND flymake didn't see anything that it recognized as error text, then flymake will throw a CFGERR and turn off.
From the flymake manual:
The following errors cause a warning message and switch flymake mode OFF for the buffer.
CFGERR : Syntax check process returned nonzero exit code, but no errors/warnings were reported. This indicates a possible configuration error (for example, no suitable error message patterns for the syntax check tool)
So what you need to do is tell flymake how to interpret the errors from your updated parser. You do this by adding a regex expression to a list that flymake will check against the output of your parser. Add something like this to your .emacs file:
(add-to-list
`flymake-err-line-patterns
'("at line \\([0-9]+\\) of \"\\([^ \n]+\\)\"$" 2 1 nil))
This will then tell flymake that if your parser generates output that matches the regex ("at line \\([0-9]+\\) of \"\\([^ \n]+\\)\"$") to identify it as an error message. The 2 1 nil tell flymake which group in the regex represents the file, line number, and column number, respectively. If the error message doesn't provide that information, then set that parameter to nil. In this example, the error message only identifies the file (second group) and line number (first group), so the column is set to nil.
Lately i've been trying to install ELI on my Linux computer!
I've followed the guide from http://www.franz.com/emacs/ to make it work! I've also searched for similar errors and found this thread http://ubuntuforums.org/showthread.php?t=1646855
However unlike the person in the forum I cannot load the fi-site-init.el file from the scratch buffer.
By opening emacs with the --debug-init flag i get the following error messege
Debugger entered--Lisp error: (file-error "Cannot open load file" "fi-site-init.el")
load("fi-site-init.el")
eval-buffer(#<buffer *load*> nil "/home/simon/.emacs" nil t) ; Reading at buffer position 82
load-with-code-conversion("/home/simon/.emacs" "/home/simon/.emacs" t t)
load("~/.emacs" t t)
#[nil "\205\264
What can be worth noticing is that in the guide they have
"/usr/local/acl82express/eli"
as the search path while i'm having
"/usr/Documents/acl82express/eli"
as path (since Allegro CL is installed there)
All in all this is what I've writed in the .emacs file
(push "/usr/Documents/acl82express/eli" load-path)
(load "fi-site-init.el")
(setq fi:common-lisp-image-name "/usr/Documents/acl82express/alisp")
(setq fi:common-lisp-image-file "/usr/Documents/acl82express/alisp.dxl")
(setq fi:common-lisp-directory "/usr/Documents/acl82express")
I am thankful for any help!
Simon Nyström
Documents is typically the name of the directory in the user home directory. It is customary to find it under /home/{user}/Documents where {user} is the currently logged in user. who am i | awk '{ print $1 }' - this is the way to find out, unless you forget :)
This directory is often times aliased with ~ (tilde) or $HOME environmental variable, so that when doing path expansion happens these "$HOME/Documents", "~/Documents" and "/home/{user}/Documents" will all point to the same directory.
Notice the leading "/"-symbol. I'm quite sure it'd have to be "/usr/Documents/acl82express/eli" for you.
It's a very easy scheme function
(define member?
(lambda (a lat)
(cond
((null? lat) #f)
(else (or (eq? (car lat) a)
(member? a (cdr lat))
))
)
)
)
However, when I pressed ,d or ,F in vim to run this function, there is an error
/home/oo/tmp/t.scm:64 read-error: no dispatch function defined for
#\F
Line: 4, Column: 21, File-Position: 64
Stream: #<SB-SYS:FD-STREAM for "file /home/oo/tmp/t.scm" {AC84DA9}>
Chris already pointed out that you tried to use Scheme code with a Common Lisp swank server.
You need to run a Scheme swank server (e.g. swank-mit-scheme.scm, also included in Slimv).
Normally Slimv should autodetect MIT scheme on Linux without any tweaking in the .vimrc. For the autodetection to work properly you need MIT Scheme installed and the scheme command be available.
I suggest that you remove any Slimv related settings from your .vimrc. Then load the .scm in Vim and type this command:
:echo SlimvSwankCommand()
If Scheme was autodetected then this should print the command that runs the Scheme swank server (search for swank-mit-scheme.scm in the output). If the autodetection was unsuccessful then either you don't have the scheme command or Slimv did not find swank-mit-scheme.scm. In this case you need to tell Slimv the command to run the Scheme swank server. You can do in by adding a similar command to your .vimrc:
let g:slimv_swank_cmd = '! xterm -e scheme --load /your-path-to/slime/contrib/swank-mit-scheme.scm &'
But do this only if autodetection fails. If you need some more assistance, please feel free to contact me, I'm the author of Slimv.
I have just install slime in emacs. And after removed all the other plugins for debuging, I found that slime seems had conflicts with autopair.(Or a bug of autopair?).In slime, when I typed C-c C-c, the minibuffer displayed error like:
error in process filter: define-key: Wrong type argument: characterp, nil
error in process filter: Wrong type argument: characterp, nil
error in process filter: define-key: Wrong type argument: characterp, nil
error in process filter: Wrong type argument: characterp, nil
Even more, the error message still alerted after I killed the slime buffer.
If I also remove the autopair plugin, slime works just fine. Can anyone tell me how to solve this?
Adding
(add-hook 'slime-repl-mode-hook
#'(lambda ()
(setq autopair-dont-activate t)))
to .emacs is the right answer. :)
From: here