Add tasks for all the new languages

This commit is contained in:
Tina Müller 2016-12-05 23:44:36 +01:00
parent 9dc3c2bb62
commit bba7bfd280
13208 changed files with 134745 additions and 0 deletions

View file

@ -0,0 +1 @@
SHELL("DIR/W")

View file

@ -0,0 +1,2 @@
cmd$="DIR/W"
SHELL(cmd$)

View file

@ -0,0 +1,4 @@
' FB 1.05.0 Win64
Shell "dir"
Sleep

View file

@ -0,0 +1,3 @@
import sys.execute
execute( if $os.startsWith('Windows') then 'dir' else 'ls' )

View file

@ -0,0 +1,14 @@
include "ConsoleWindow"
local fn DoUnixCommand( cmd as str255 )
dim as str255 s
open "Unix", 2, cmd
while ( not eof(2) )
line input #2, s
print s
wend
close 2
end fn
fn DoUnixCommand( "ls -A" )

View file

@ -0,0 +1 @@
> (os:cmd "ls -alrt")

View file

@ -0,0 +1 @@
> (io:format (os:cmd "ls -alrt"))

View file

@ -0,0 +1,8 @@
local(
path = file_forceroot,
ls = sys_process('/bin/ls', (:'-l', #path)),
lswait = #ls -> wait
)
'<pre>'
#ls -> read
'</pre>'

View file

@ -0,0 +1,6 @@
sx = xtra("Shell").new()
if the platform contains "win" then
put sx.shell_cmd("dir")
else
put sx.shell_cmd("ls")
end if

View file

@ -0,0 +1,4 @@
import osproc
let exitCode = execCmd "ls"
let (output, exitCode2) = execCmdEx "ls"

View file

@ -0,0 +1 @@
System cmd("pause")

View file

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

View file

@ -0,0 +1 @@
system("dir")

View file

@ -0,0 +1,10 @@
# Pipe in read-only mode
%p(ls).open_r.each { |line|
print line;
};
var str1 = `ls`; # backtick: returns a string
var str2 = %x(ls); # ditto, alternative syntax
Sys.system('ls'); # system: executes a command and prints the result
Sys.exec('ls'); # replaces current process with another

View file

@ -0,0 +1,11 @@
decl string<> arg
decl string<> output
decl iodevice iod
append "ls" arg
set iod (ursa.util.process.start arg)
set output (iod.readlines)
for (decl int i) (< i (size output)) (inc i)
out output<i> endl console
end for

View file

@ -0,0 +1 @@
system "ls"