assess with file contents literally?
Hi again,
Thanks for the recent changes and new version.
I see that assess-file loads a file with insert-file-contents. In a test I'm working on, I need to test with normally-inserted file contents like this, but also with insert-file-contents-literally. Is there a way that this could be supported in assess?
Thanks.
With the implementation at the moment, this part of assess is not freely extensible, which is something I need to think about it I guess, but you can always convert the file itself.
(assess=
"Hello"
(with-temp-buffer
(insert-file-contents-literally f)
(buffer-string)))
Or:
(defun my-literal-file (filename)
(with-temp-buffer
(insert-file-contents-literally filename)
(buffer-string)))
To be honest, my implementation at the moment is a bit round-about. assess-file currently returns a list which is interpreted by assess-to-string, which then makes a string. Probably makes more sense if assess-file (and assess-buffer) just returned the string directly.
I shall think on this.
Long delay! I've updated assess so that "assess-file" and the like so that they return strings directly. If you are still needing the "insert-file-contents-literally" it can be added easily now.