3 ms·
Can you please elaborate a bit on the textmate approach? I don't fully grasp it from this description yet... while it totally sounds interesting...
by akavel 8y ago
Can you please elaborate a bit on the textmate approach? I don't fully grasp it from this description yet... while it totally sounds interesting...
- traviscj 8y agoI (partially) recreated your `seq 1 15` example here [1] -- no sleep, but my lshw wasn't as interesting as yours :-) I'm hitting command-shift-| to bring up the "filter through command" dialog. [1]: https://tcj.io/i/textmate_piping.gif https://tcj.io/i/textmate_piping.gif
- akavel 8y agoOk, I get it now. Thanks! :)
- em-bee 8y agoi have not used textmate, but the description let me come up with this idea. maybe it's useful: consider the command A | B | C | D when you process it in up, split the command at the | and process each one separately. that is first run A; save the output into a buffer (BA) then pipe BA into B, save that into BB, and so on, until you have 4 buffers containing the outputs of A; A|B; A|B|C; and A|B|C|D; now when the user edits, you can see which section is changed. say the user changes the command C into C1, so the pipeline becomes: A|B|C1|D at this point you can pipe buffer BB (which has the output from A|B) into C1; write that into a new buffer BC1; and pipe that into D; the old buffers C and D can be removed at this point, or you can keep them around in case the user undoes their change and goes back to an old version. greetings, eMBee.