Use $MSYSTEM and 'bash -lc' in MinGW CI Setting the $MSYSTEM environment variable and invoking shell scripts with 'bash -lc' sets up the correct MinGW environment. See https://www.msys2.org/docs/ci/