talira

process_run

Run shell scripts and find executables from Dart on Linux, Windows and macOS

open sourceBSD-2-Clausefree

process_run is a Dart package for running external commands and multi-line scripts in a portable way on Linux, Windows and macOS. Its Shell class runs a script line by line, with options for the working directory, environment and error handling, and its which helpers find installed executables the way Unix which does. A shell command-line utility changes the variables, paths and aliases Shell uses. The package ships agent skills for its shell, environment and tools APIs.

Problems it solves

  • run shell commands from a Dart script on any OS
  • find where an executable like flutter is installed from Dart code
  • run a multi-line build script from a Dart tool

Features

  • Shell runs multi-line scripts portably on Linux, Windows and macOS
  • which and whichSync find installed executables
  • shell command-line utility to set the environment, paths and aliases Shell uses
  • ships agent skills for its shell, environment and tools APIs

Limitations

  • Running executables from a sandboxed macOS Flutter app needs the app sandbox entitlement turned off.1