flutter_pty
flutter_pty copied to clipboard
example doesnt work in release mode on macos
i tried the example in the release mode on macos and it didn't recognise the command brew, I tried running brew --version in debug mode it works.
Related: https://github.com/Homebrew/brew/issues/15833
You can fix it by adding
final homeDir = Platform.environment['HOME'] ?? '';
pty.write(const Utf8Encoder().convert('export HOME=$homeDir' + carriageReturn));
after pty.start.
This sets $HOME which is needed by process for it to be able to run brew.
will it be able to run ffmpeg or any other installed tools too this way?
From my test on my machine™️ it will