Sat, 19 Sep 2015 13:19:54 EDT

test text in /dev/snarf: {{{ }}}

test: {{{ echo ‘,x/^/i/./ ,x/\n/c/ / ,x/ +$/c/\n/ w ’ | sam -d /dev/snarf }}}

the last regexp, / +$/, doesn’t match because all the newlines have been deleted.

i confirmed it’s the $ which doesn’t match by eliminating the other parts; it matched only when i added a space to the end of in the source and changed the regexp to just two spaces, no $.

acme doesn’t have this bug, but produces ‘warning: changes out of sequence’. this warning appears to be nonsense. if it followed the expressions according to the syntax, how could it make the changes out of order? obviously acme can’t be scripted in the same way. i tested it by selecting all within the quotes in the test above, and applying it to Edit on a window containing the test text.