nv-elispB
Long story short, they’re not being compiled. The message is just output every time. There is a thread on emacs-devel or emacs-bug archive which offers a more detailed explanation if you search there.
Auctex requires a :pre-build step which involves generating elisp files. If that step fails, certain parts will break. There are several ways to configure the build as well. See the various issues on the bug tracker for more info. e.g,
Customize display-buffer-alist
to your liking. There is an Emacs manual section devoted to it as well as several online tutorials.
You don’t have anything to guard against a bad response from the server. e.g.
(unless (equal url-http-response-status 200)
(error "Server responded with status: %S" url-http-response-status))
To position point at the end of the headers:
(goto-char url-http-end-of-headers)
This:
(setq result (cons (cons ...) result))
Is more clearly expressed as:
(push (cons ...) result)
Better yet, you could map over the elements you’re interested in and accumulate the results via mapcar
or cl-loop
.
That would obviate the need for the “results” variable.
You could probably shorten things by using the dom-elements
function to directly search for the href’s you’re interested in in combination with dom-parent to get at the parent elements.
Overall your function gets a 65 out of 130 ERU (elisp rating units).
(add-variable-watcher 'autosave-toggle
#'(lambda (_ value _ _)
(if value (autosave-setup) (autosave-teardown))))
Don’t add an anonymous function. It will make it harder to remove. Better yet, implement this as a minor-mode.
(defvar autosave-delay-interval 1
"The amount of time to wait before autosaving after a change has occurred.")
(defvar autosave-exclude-buffer-list
'("COMMIT_EDITMSG" "treemacs-persist")
"List of buffers to exclude from autosaving")
(defvar autosave-immediate-save-functions-list
'(switch-to-buffer other-window windmove-up windmove-down windmove-left windmove-right next-buffer previous-buffer)
"A list of functions which trigger an immediate save")
(defvar autosave-immediate-save-hooks-list
'(mouse-leave-buffer-hook focus-out-hook)
"A list of hooks which trigger an immediate save")
These should be user options defined via defcustom
(defmacro advice-add-list (advice-list how function)
"Add list of advice to given function using the how parameter"
`(dolist (advice ,advice-list)
(advice-add advice ,how ,function)))
(defmacro advice-remove-list (advice-list function)
"Remove list of advice from given function using the how parameter"
`(dolist (advice ,advice-list)
(advice-remove advice ,function)))
(defmacro add-hooks (hook-list function)
"Add list of hooks to given function"
`(dolist (hook ,hook-list)
(add-hook hook ,function)))
(defmacro remove-hooks (hook-list function)
"Remove list of hooks from given function"
`(dolist (hook ,hook-list)
(remove-hook hook ,function)))
These should be functions instead of macros. They should also be prefixed with your package’s “namespace”.
Two days ago: https://www.reddit.com/r/emacs/comments/17k6pu4/m_aka_mx_evalexpression_does_nothing_upon_hitting/
What have you tried/searched for?
Pointless. Not entertaining or informative.
RGB underglow… 90s vibe
Were you alive in the 90s?