September Morn Update

This commit is contained in:
Ingy döt Net 2019-09-12 10:33:56 -07:00
parent 4e2d22a71d
commit aac6731f2c
6856 changed files with 141342 additions and 21127 deletions

View file

@ -1,4 +1,4 @@
run "ls" or die $!; # output to stdout
run "ls" orelse .die; # output to stdout
my @ls = qx/ls/; # output to variable

View file

@ -1,13 +1,9 @@
my @results = qx(ls);
# runs command and returns its STDOUT as a string
my @results = `ls`;
# ditto, alternative syntax
my @results = qx(ls); # run command and return STDOUT as a string
system "ls";
# runs command and returns its exit status; its STDOUT gets output to our STDOUT
my @results = `ls`; # same, alternative syntax
print `ls`;
#The same, but with back quotes
system "ls"; # run command and return exit status; STDOUT of command goes program STDOUT
exec "ls";
# replace current process with another
print `ls`; # same, but with back quotes
exec "ls"; # replace current process with another

View file

@ -1,3 +1,3 @@
string cmd = {"dir","ls"}[platform()-1]
string cmd = iff(platform()=WINDOWS?"dir":"ls")
system(cmd)
integer res = system_exec("pause",4)