2021-01-25 21:08:05 +00:00
|
|
|
#if 0
|
|
|
|
/*─────────────────────────────────────────────────────────────────╗
|
|
|
|
│ To the extent possible under law, Justine Tunney has waived │
|
|
|
|
│ all copyright and related or neighboring rights to this file, │
|
|
|
|
│ as it is written in the following disclaimers: │
|
|
|
|
│ • http://unlicense.org/ │
|
|
|
|
│ • http://creativecommons.org/publicdomain/zero/1.0/ │
|
|
|
|
╚─────────────────────────────────────────────────────────────────*/
|
|
|
|
#endif
|
2024-09-11 09:14:38 +00:00
|
|
|
#include <stdlib.h>
|
2021-01-25 21:08:05 +00:00
|
|
|
|
2022-10-14 23:37:29 +00:00
|
|
|
/**
|
|
|
|
* @fileoverview Cosmopolitan Command Interpreter Demo
|
|
|
|
* Yes this works on Windows.
|
|
|
|
*/
|
|
|
|
|
2023-07-26 20:54:49 +00:00
|
|
|
__static_yoink("_tr");
|
|
|
|
__static_yoink("_sed");
|
2022-10-14 23:37:29 +00:00
|
|
|
|
2021-01-25 21:08:05 +00:00
|
|
|
int main(int argc, char *argv[]) {
|
2022-10-14 23:37:29 +00:00
|
|
|
system("x=world\n"
|
|
|
|
"echo hello $x |\n"
|
|
|
|
" tr a-z A-Z |\n"
|
|
|
|
" sed 's/\\(.\\)/\\1 /g'");
|
2021-01-25 21:08:05 +00:00
|
|
|
}
|