assess
provides additional support for testing Emacs packages.
It provides:
A set of predicates for comparing strings, buffers and file contents.
Explainer functions for all predicates giving useful output.
Macros for creating many temporary buffers at once, and for restoring the buffer list.
Methods for testing indentation, by comparision or roundtripping.
Methods for testing fontification.
Assess aims to be a stateless as possible, leaving Emacs unchanged whether the tests succeed or fail, with respect to buffers, open files and so on. This helps to keep tests independent from each other.
To allow for the usage of Emacs functions and macros that are defined in newer versions of Emacs, compat.el
provides definitions that are installed ONLY if necessary. These reimplementations of functions and macros are at least subsets of the actual implementations. Be sure to read the documentation string to make sure.
Not every function provided in newer versions of Emacs is provided here. Some depend on new features from the core, others cannot be implemented to a meaningful degree. The main audience for this library are not regular users, but package maintainers. Therefore commands and user options are usually not implemented here.
This package provides a sort of right-click contextual menu for Emacs offering you relevant actions to use on a target determined by the context.
In the minibuffer, the target is the current best completion candidate. In the *Completions*
buffer the target is the completion at point. In a regular buffer, the target is the region if active, or else the file, symbol or URL at point.
The type of actions offered depend on the type of the target. For files you get offered actions like deleting, copying, renaming, visiting in another window, running a shell command on the file, etc. For buffers the actions include switching to or killing the buffer. For package names the actions include installing, removing or visiting the homepage.
pcache provides a persistent way of caching data, in a hashtable-like structure. It relies on `eieio-persistent in the backend, so that any object that can be serialized by EIEIO can be stored with pcache. pcache handles objects called "repositories" (`pcache-repository') and "entries" (`pcache-entry'). Each repository is identified by a unique name, that defines an entry in `pcache-directory'. Subdirectories are allowed, by the use of a directory separator in the repository name. Example: (let ((repo (pcache-repository "plop"))) (pcache-put repo foo 42) ; store value 42 with key foo (pcache-get repo foo) ; => 42 ) Keys can be pretty much any Lisp object, and are compared for equality using `eql Optionally, cache entries can expire: (let ((repo (pcache-repository "plop"))) (pcache-put repo foo 42 1) ; store value 42 with key foo for 1 second (sleep-for 1) (pcache-get repo foo) ; => nil )
Do trivial arithmetic on the numbers at point. Attempts to preserve padding when it can. Examples: M-x number/add 1 RET 1 -> 2 05 -> 06 6.30 -> 7.30 07.30 -> 08.30 -08.30 -> -07.30 M-x number/pad 2 RET 5 -> 05 M-x number/pad 2 RET 6 RET 3.141 -> 03.141000 The "guessing" where the number is isn't yet quite awesome, e.g. it doesn't know that the 05 in "2014-05-01" is a month and not, e.g. the number -05. But you can use the region to explicitly denote the start and end of the number. The following keybindings might be nice to use: (global-set-key (kbd "C-c C-+") number/add) (global-set-key (kbd "C-c C--") number/sub) (global-set-key (kbd "C-c C-*") number/multiply) (global-set-key (kbd "C-c C-/") number/divide) (global-set-key (kbd "C-c C-0") number/pad) (global-set-key (kbd "C-c C-=") number/eval)
Documentation at https://melpa.org/#/emacsql
Documentation at https://melpa.org/#/pdfgrep
Documentation at https://melpa.org/#/nemerle
Documentation at https://melpa.org/#/omnibox
Documentation at https://melpa.org/#/yahtzee
Documentation at https://melpa.org/#/esonify
Documentation at https://melpa.org/#/windwow
Documentation at https://melpa.org/#/idomenu
Documentation at https://melpa.org/#/pastery
Documentation at https://melpa.org/#/capture
Documentation at https://melpa.org/#/ordinal
Documentation at https://melpa.org/#/promise
Documentation at https://melpa.org/#/noether