drun 2.8.0

  • Readme
  • Changelog
  • Example
  • Installing
  • 73

drun #

Pub Version .github/workflows/main.yml semantic-release Conventional Commits KeepAChangelog License

A dartlang task runner, write functions and call them in your terminal.

Installation #

  • Install dartlang https://dart.dev/get-dart
  • Then install drun globally: pub global activate drun
  • Then install drun into your local project where your Makefile.dart resides.

Experimental dart2native binaries #

You may prefer to install the global drun command as single statically compiled binary.

NOTE: You still need the dart SDK installed!

Direct download

Go to https://github.com/brad-jones/drun/releases and download the archive for your Operating System, extract the drun binary and and add it to your $PATH.

Curl Bash

curl -L https://github.com/brad-jones/drun/releases/latest/download/drun-linux-x64.tar.gz -o- | sudo tar -xz -C /usr/bin drun

RPM package

sudo rpm -i https://github.com/brad-jones/drun/releases/latest/download/drun-linux-x64.rpm

DEB package

curl -sLO https://github.com/brad-jones/drun/releases/latest/download/drun-linux-x64.deb && sudo dpkg -i drun-linux-x64.deb && rm drun-linux-x64.deb

Homebrew

https://brew.sh

brew install brad-jones/tap/drun

Scoop

https://scoop.sh

scoop bucket add brad-jones https://github.com/brad-jones/scoop-bucket.git;
scoop install drun;

Usage #

Makefile.dart

import 'package:drun/drun.dart';

Future<void> main(argv) async => drun(argv);

void myTask() {
  print('Mello World');
}

Execute with drun my-task

see ./example/README.md for more details

2.8.0 (2020-05-20) #

Features #

  • hidesubtasks: add the ability to hide sub tasks from help txt (39109b5)

2.7.0 (2020-05-20) #

Features #

  • help: list sub tasks seperatly from primary tasks (77fa29d)

2.6.1 (2020-05-20) #

Bug Fixes #

  • reflect: it is possible to have multiple prefixes of the same name (2a28ac5)

2.6.0 (2020-05-19) #

Features #

  • run: functin that combines the other runX functions (8dce0f1)

2.5.0 (2020-05-19) #

Features #

  • runifchanged: function that executes only if files have changed (d1bd522)

2.4.1 (2020-05-19) #

Bug Fixes #

  • pubspec: crypto is now a lib dependency (2bed7ec)

2.4.0 (2020-05-19) #

Features #

  • runifnotfound: new function that only runs if files are not found (486c245)

2.3.0 (2020-05-19) #

Features #

  • runonce: will run a task only once for a single drun execution (deae68f)

2.2.0 (2020-05-19) #

Features #

  • log: add some simple logging functionality (1348950)

2.1.1 (2020-05-14) #

Bug Fixes #

  • reflect: allow other types of members inside options class (a4ff2df)

2.1.0 (2020-05-08) #

Features #

  • drun the binary now installs dart and run pub get if needed (5b18bdf)

2.0.3 (2020-05-07) #

Bug Fixes #

  • archives: make sure the execute bit is set (2bc9912)

2.0.2 (2020-04-22) #

Bug Fixes #

  • windows: strip leaing slash from root makefile path (dba938b)

2.0.1 (2020-04-22) #

Bug Fixes #

  • windows: normalize paths when looking for root makefile (5271990)

2.0.0 (2020-04-22) #

Features #

  • global-options: allow options to be shared between tasks (3037980)

BREAKING CHANGES #

  • global-options: fairly significant changes although none are breaking I believe, but without a test suite it's hard to say. If this is v2, then v3 will include a full test suite, I promise :)

1.1.5 (2020-04-15) #

Bug Fixes #

  • windows: updated dexecve which uses ProcessStartMode.inheritStdio (4a33877)

1.1.4 (2020-04-15) #

Bug Fixes #

  • stdin: another fix for dexecve (642a510)

1.1.3 (2020-04-15) #

Bug Fixes #

  • help: format option names with param-case (0cbcfbf)
  • stdin: the new version of dexecve should handle stdin (2b8e084)

1.1.2 (2020-03-18) #

Bug Fixes #

  • binary: make use of our new packages dexeca and dexecve (efea46d)

1.1.1 (2020-03-18) #

Bug Fixes #

  • example: renamed the file to main.dart (7b6ddda)

1.1.0 (2020-03-18) #

Features #

1.0.11 (2020-03-10) #

Bug Fixes #

  • release: search and replace logic incorrect (54c0e25)

1.0.10 (2020-03-10) #

Bug Fixes #

  • release: github actions is kind of a pain (284eb1e)

1.0.9 (2020-03-10) #

Bug Fixes #

  • release: actually I don't think we need this at all (bed5970)
  • release: make commits uses semantic-release-bot (31c04ff)

1.0.8 (2020-03-10) #

Bug Fixes #

  • release: well I believe this is sorted now (e9621f5)

1.0.7 (2020-03-10) #

Bug Fixes #

1.0.6 (2020-03-10) #

Bug Fixes #

  • release: perhaps our expiration logic is not correct (c9fecc8)

1.0.5 (2020-03-10) #

Bug Fixes #

  • release: added git email and name to allow git changes to be pushed (b4a8d3c)

1.0.4 (2020-03-10) #

Bug Fixes #

  • release: more debugging (9bec3d9)

1.0.3 (2020-03-10) #

Bug Fixes #

  • release: this is not making any sense, sorry for the dud releases (02fa62d)

1.0.2 (2020-03-10) #

Bug Fixes #

  • release: homebrew and scoop failed to release due to git auth issue (568d3b1)

1.0.1 (2020-03-10) #

Bug Fixes #

  • description: pub.dev told us our description is too short (418dc03)

1.0.0 (2020-03-10) #

Features #

example/README.md

drun example #

This folder contains a contrived example that shows how you could structure your makefiles, it is a working example of all features and functionality.

Use this package as an executable

1. Install it

You can install the package from the command line:


$ pub global activate drun

2. Use it

The package has the following executables:


$ drun

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  drun: ^2.8.0

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:drun/drun.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
47
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100
Overall:
Weighted score of the above. [more]
73
Learn more about scoring.

We analyzed this package on May 26, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.8.1
  • pana: 0.13.8-dev

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.7.0 <3.0.0
ansicolor ^1.0.2 1.0.2
archive ^2.0.13 2.0.13
args ^1.5.3 1.6.0
async ^2.4.1 2.4.1
console ^3.1.0 3.1.0
convert ^2.1.1 2.1.1
crypto ^2.1.4 2.1.5
dexeca ^1.0.1 1.3.0
dexecve ^1.1.0 1.3.0
dotenv ^2.0.0 2.0.0
glob ^1.2.0 1.2.0
http ^0.12.1 0.12.1
io ^0.3.3 0.3.4
path ^1.7.0 1.7.0
recase ^3.0.0 3.0.0
stack_trace ^1.9.3 1.9.3
Transitive dependencies
charcode 1.1.3
collection 1.14.12
dart2_constant 1.0.2+dart2
ffi 0.1.3
http_parser 3.1.4
js 0.6.1+1
meta 1.1.8
node_interop 1.1.1
node_io 1.1.1
source_span 1.7.0
string_scanner 1.0.5
term_glyph 1.1.0
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
pedantic ^1.8.0 1.9.0
pretty_json ^1.0.8
test ^1.14.1