// returns file with program output (STDOUT+STDERR) static File backtickToConsole_lineBuf(S cmd, fO onLine) { O onOutput = new O { new LinesBuffer buf; void get(S s) { buf.append(fixNewLines(s)); for (S line : buf.getAndClearCompleteLines()) pcallF(onLine, line); } }; ret backtickToConsoleX(cmd, onOutput); }
Began life as a copy of #1009098
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1009576 |
Snippet name: | backtickToConsole_lineBuf - run external process, print its output to Java console and call function on output lines |
Eternal ID of this version: | #1009576/4 |
Text MD5: | bd141fb85c881a825720d2ba48014f44 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-08-08 21:40:14 |
Source code size: | 364 bytes / 14 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 439 / 469 |
Version history: | 3 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |