Hey Andrea! :) On Mon, Apr 25, 2011 at 11:03:01AM +0200, Andrea Crotti wrote: > Luca Barbato <[email protected]> writes: > > > > I didn't mean in the code, I mean enabling it so people using emacs > > will get their file whitespace clean on save, (I already posted my > > vimrc for that) > > Ah now I got it I thought you were still referring to how the patch was > generated. > > Well for that I have this function here below which could hooked to > before-save-hook, in this way every time you save a file, it first > cleans up everything and then save it. > > (defun cleanup-buffer () > "Perform a bunch of operations on the whitespace content of a buffer." > (interactive) > (indent-buffer) > (untabify-buffer) > (delete-trailing-whitespace)) > > I'll write in another post a more complete example of which variables > have to be modified.
I'm a bit suspicious about indent-buffer, that might introduce stray changes ... > > I know =), the best probably would be adding an autotemplate so we > > create new files with the default headers automagically (hadn't made > > that for vim yet) > > > > Thank you for the support ^^ > > Yes that's very straight forward, I actually use yasnippet for that but > since it's not part of the "standard" emacs, something else can be done, > depending on how smart the template has to be. Something like this would actually be very useful. Diego P.S.: Your mailer breaks threads, you should fix that. _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
