From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Emanuel Berg Newsgroups: gmane.emacs.help Subject: Re: Why isn't ert-buffer.el part of Emacs? Date: Sat, 14 Jun 2014 14:54:02 +0200 Organization: Aioe.org NNTP Server Message-ID: <87lhsztzx1.fsf@debian.uxu> References: <871tusxuxe.fsf@debian.uxu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1402750524 30691 80.91.229.3 (14 Jun 2014 12:55:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 14 Jun 2014 12:55:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jun 14 14:55:19 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WvnUM-0004hm-Uh for geh-help-gnu-emacs@m.gmane.org; Sat, 14 Jun 2014 14:55:19 +0200 Original-Received: from localhost ([::1]:35265 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WvnUM-0001oT-IP for geh-help-gnu-emacs@m.gmane.org; Sat, 14 Jun 2014 08:55:18 -0400 Original-Path: usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!news.stack.nl!aioe.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 75 Original-NNTP-Posting-Host: SIvZRMPqRkkTHAHL6NkRuw.user.speranza.aioe.org Original-X-Complaints-To: abuse@aioe.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) X-Notice: Filtered by postfilter v. 0.8.2 Cancel-Lock: sha1:H4YXgC8IDTSoWQ3DMK+XZTVhOvc= Mail-Copies-To: never Original-Xref: usenet.stanford.edu gnu.emacs.help:205979 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:98249 Archived-At: Thorsten Jolitz writes: >>> I recently discovered 'ert-buffer.el' and find it >>> very useful. It is introduced and discussed here >>> ... I wonder why such a generally useful library >>> isn't included in Emacs (I don't even find it in >>> the package repos)? >>> >> I stopped reading here, because I don't have any >> comments on that specific software. But, in >> general, I have found tons of useful stuff that >> isn't included, and I have written tons of stuff >> that I think should be included, perhaps not my >> implementation specifically, but rather the >> functionality. > > I stopped reading here, because It was ... too long > ;) > > Of course the Emacs universe is almost infinite, and > by far not everything belongs into core. But since > the buffer is *the* fundamental concept of Emacs, > writing tests that compare buffer states appear like > a core task. I don't know if the buffer is the fundamental concept of Emacs, one of many fundamentals, perhaps... But fundamental or not, I would assume there is tons of buffer-related stuff around that are just spread across countless of .el and .emacs files and won't ever make it to the official release. For example, I wrote this (setq buffer-menu-buffer-font-lock-keywords '(("[[:space:]]+\\([[:digit:]]+\\)[[:space:]]+" (1 font-lock-comment-delimiter-face)) ("\\*\\(Messages\\|Backtrace\\)\\*" . font-lock-comment-face) ("\\*scratch\\*" . 'font-lock-regexp-grouping-construct) ("\\*Help\\*" . font-lock-constant-face) ("\\*Group\\*" . font-lock-doc-face) ("\\(\\*Man\\) \\(.*\\)\\(\\*\\) " (1 font-lock-type-face) (2 font-lock-negation-char-face) (3 font-lock-type-face) ) ("[[:space:]%*.]*\\(.*\\.el\\) " (1 font-lock-string-face)) ("[[:space:]%*.]*\\(.*\\.\\(c\\|cpp\\)\\) " (1 font-lock-function-name-face) ) ("[[:space:]%*.]*\\(.*\\.\\(txt\\|html\\|htm\\)\\) " (1 font-lock-function-name-face) ) ("[[:space:]%*.]*\\(.*\\.\\(h\\|hh\\|tex\\)\\) " (1 font-lock-variable-name-face) ) ("[[:space:]%*.]*\\( \\.[[:alnum:]\\_\\.\\-]*\\) " (1 font-lock-type-face) ) ("\\*w3m\\*" . 'font-lock-regexp-grouping-backslash) (".*\\(<[0-9]>\\) " (1 font-lock-negation-char-face)) ("\\(KILL\\|my-kill\\) " . font-lock-warning-face) )) so that the buffer menu wouldn't look so boring: screenshot here - http://user.it.uu.se/~embe8573/buffer_menu.png The buffer menu is central but I don't think anyone will include that just the same. > Can it be done easily with included ERT libraries > (using real world buffers too)? I'm not the expert > here, but at least it is not obvious how to do it > without reimplementing (parts of) ert-buffer.el > (probably over and over again ...) In this particular case, what does it matter? You have the code you need so just use it, I would say. -- underground experts united: http://user.it.uu.se/~embe8573