archInfo function

Future<String> archInfo()

Implementation

Future<String> archInfo() {

  return Isolate.run(()async {
    final processResult = await Process.run(
      "uname",
      [(Dart.isAndroid) ? "-m" : "-p"],
    );
    final res = processResult.stdout;
    if (res is String) {
      return res;
    } else {
      return "";
    }
  });
  // if (Dart.isAndroid) {
  //   Process.run("uname", arguments);
  //   // asnrv
  //   return Process.runSync("uname", [
  //     "-m",
  //   ]).stdout.toString().trim();
  // }
  // return Process.runSync("uname", ["-p"]).stdout.toString().trim();
}