Pipecom - Cross-platform Alternative to ShellAuthor:
@SpriggsySpriggsSource: qb64.org Forum
URL:
https://www.qb64.org/forum/index.php?topic=3641.msg129938#msg129938Version: Visit author's URL
Tags: [OS information]
Description:
pipecom is a cross-platform utility for directly obtaining console output in Windows, Mac, and Linux. Previously, one would need to use files.There are 2 versions.
Basic usage for returning back console output as a string only:
MyOSInquiry$ = pipecom_lite("OS line command")
As expected from "lite", this just returns the answer as a string.
Usage for returning back stdout, stderr, and exit codes:
Dim As String stdout
, stderrexit_code
= pipecom
("dir /b *.bas", stdout
, stderr
) 'print or manipulate values as you see fit
Note: Code posted here would be redundant and not up-to-date . The author is continuously making updates for improvement.
Go to the URL above.