On Fri, 10 May 2019, Andrew Bernard wrote:
Add this code to ~/.vimrc: " lilypond reformat (acb) " reformat buffer, and return cursor to about the same place. fun DoLilypondReformat() let l = line(".") let c = col(".") :%!ly reformat call cursor(l, c) endfun au Filetype lilypond nmap <F2> :call DoLilypondReformat()<CR>
Great! That's very useful! But the indentation of the code between fun and endfun gave errors on my system. After unindenting these lines your code worked perfectly.
-- MT
_______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user