Get system command output: Difference between revisions

Get system command output in Yabasic
m (Fix dead documentation urls)
(Get system command output in Yabasic)
Line 1,677:
vm.Free()
}</lang>
 
=={{header|Yabasic}}==
<lang yabasic>// Rosetta Code problem: https://www.rosettacode.org/wiki/Get_system_command_output
// by Jjuanhdez, 06/2022
 
if peek$("os") = "unix" then
c$ = "ls *"
else //"windows"
c$ = "dir *.*"
fi
 
open("dir_output.txt") for writing as #1
print #1 system$(c$)
close #1</lang>
 
=={{header|zkl}}==
2,130

edits