commit | 7993b642642c5df4dfc514268931943fef74bc0c | [log] [tgz] |
---|---|---|
author | Phil Quitslund <pq@users.noreply.github.com> | Thu May 21 20:41:22 2015 |
committer | Phil Quitslund <pq@users.noreply.github.com> | Thu May 21 20:41:22 2015 |
tree | c0f4b2b78390bb4d9d511960f0f9203bf164a272 | |
parent | 4e47de5b6be9a16a67b2a3802850eaf2a9ea0483 [diff] |
Update README.md Badge fix.
Check for and locate installed executables. Just like unix which(1), except:
pub global activate den den install which
import 'dart:io'; import 'package:which/which.dart'; main(arguments) async { // Asynchronously var git = await which('git', orElse: () => null); // Or synchronously var git = whichSync('git', orElse: () => null); if (git == null) { print('Please install git and try again'); exit(1); } await Process.run(git, ['add', '-A']); await Process.run(git, ['commit', '-m', arguments.first]); }