1 | static bool directNohupJava_loggingOn = true; |
2 | |
3 | static File directNohupJavax(S javaxargs) { |
4 | ret directNohupJavax(javaxargs, javaxDefaultVMArgs()); |
5 | } |
6 | |
7 | static File directNohupJavax(fS _javaxargs, fS _vmArgs) { |
8 | if (directNohupJava_loggingOn) |
9 | //thread { |
10 | //S title = "?"; |
11 | //pcall { title = getSnippetTitle(parseFirstInt(javaxargs)); } |
12 | appendToLocalMechLog("nohupJavax Log", sfu(dropSecondIfEmpty(str(parseFirstInt(_javaxargs)), _vmArgs))); |
13 | //} |
14 | // TODO: handle "-case 123 1009326" |
15 | S javaxargs = _javaxargs.trim(); |
16 | if (javaxargs.startsWith("#")) javaxargs = javaxargs.substring(1); |
17 | S snippetID = javaTok(javaxargs).get(1); |
18 | int idx = javaxargs.indexOf(' '); |
19 | S args = idx < 0 ? "" : javaxargs.substring(idx+1).trim(); |
20 | |
21 | S vmArgs = trim(_vmArgs); |
22 | if (empty(vmArgs) && usePreSpunVMs()) { |
23 | S line; |
24 | if (args.length() != 0) |
25 | line = format3("please start program * with arguments *", snippetID, args); |
26 | else |
27 | line = format3("please start program *", snippetID); |
28 | S answer = sendToLocalBotOpt("A pre-spun VM.", line); |
29 | if (match3("ok", answer)) { |
30 | print("OK, used pre-spun VM."); |
31 | null; |
32 | } |
33 | if (answer != null) |
34 | print("> " + answer); |
35 | print("Using standard nohup."); |
36 | } |
37 | |
38 | ret classicNohupJavax(javaxargs, vmArgs); |
39 | } |
Began life as a copy of #1001372
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1009117 |
Snippet name: | directNohupJavax - start new independent JavaX VM [direct version] |
Eternal ID of this version: | #1009117/15 |
Text MD5: | be8fb9b768467561aff8ae56b57bcef6 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-06-13 14:11:19 |
Source code size: | 1327 bytes / 39 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 710 / 728 |
Version history: | 14 change(s) |
Referenced in: | [show references] |