() Andrew Gwozdziewycz <apg...@gmail.com> () Thu, 8 Mar 2012 11:57:48 -0500
Not to strike you down twice, No worries, the mud's fine. but I'm not sure how .screenrc's syntax would be better served with s-expressions. To my knowledge it's completely line oriented without any sort of section delimiting. Here's a fragment from my ~/.screenrc: # special xterm hardstatus: use the window title. termcap xterm 'hs:ts=\E]2;:fs=\007:ds=\E]0;Screen\007' terminfo xterm 'hs:ts=\E]2;:fs=\007:ds=\E]0;Screen\007' It shows a comment and two directives of the form: CATEGORY KEY VALUE Since KEY and VALUE are identical, it would be nice to be able to express that using some kind of ‘for-each’ or ‘map’ expression. Furthermore, IWBN to compose the string from meaningful bits instead of having to cart around (for 15 years, no less :-) such grot... (define (both-termcap-and-terminfo name value) ;; do ‘termcap NAME VALUE’ ;; do ‘terminfo NAME VALUE’ ) (both-termcap-and-terminfo 'xterm (string-join (map format-attribute '(hs (ts escape "]2;") (fs bell) (ds escape "]0;Screen" bell))) ":")) or something like that.