Skip to content

Commit

Permalink
Merge pull request #307 from google/bug_fix
Browse files Browse the repository at this point in the history
fix a bug in ddc's --html-report cli option
  • Loading branch information
devoncarew committed Nov 13, 2015
2 parents 1a1b5ff + e38c3f1 commit 5903f37
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 12 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# grinder.dart changes

## 0.8.0+1 (2015/11/12)
- Fixed a bug with the DDC `--html-report` option

## 0.8.0 (2015/10/29)
- Removed deprecated constants: BIN_DIR, BUILD_DIR, LIB_DIR, WEB_DIR
- Removed the 120-col line wrapping on task output
Expand Down
20 changes: 10 additions & 10 deletions lib/grinder_tools.dart
Original file line number Diff line number Diff line change
Expand Up @@ -146,46 +146,46 @@ class DevCompiler {
DevCompiler();

/// Analyze the given file or files with DDC.
void analyze(dynamic files, {bool htmlOutput: false}) {
_ddc.run(_args(files, htmlOutput: htmlOutput));
void analyze(dynamic files, {bool htmlReport: false}) {
_ddc.run(_args(files, htmlReport: htmlReport));
}

/// Analyze the given file or files with DDC.
Future analyzeAsync(dynamic files, {bool htmlOutput: false}) {
return _ddc.runAsync(_args(files, htmlOutput: htmlOutput));
Future analyzeAsync(dynamic files, {bool htmlReport: false}) {
return _ddc.runAsync(_args(files, htmlReport: htmlReport));
}

/// Compile the given file with DDC and generate the output to [outDir].
void compile(dynamic files, Directory outDir, {
bool forceCompile: false,
bool htmlOutput: false
bool htmlReport: false
}) {
_ddc.run(_args(files,
outDir: outDir,
forceCompile: forceCompile,
htmlOutput: htmlOutput));
htmlReport: htmlReport));
}

/// Compile the given file with DDC and generate the output to [outDir].
Future compileAsync(dynamic files, Directory outDir, {
bool forceCompile: false,
bool htmlOutput: false
bool htmlReport: false
}) {
return _ddc.runAsync(_args(files,
outDir: outDir,
forceCompile: forceCompile,
htmlOutput: htmlOutput));
htmlReport: htmlReport));
}

List<String> _args(dynamic files, {
Directory outDir,
bool forceCompile: false,
bool htmlOutput: false
bool htmlReport: false
}) {
List<String> args = [];
if (outDir != null) args.add('-o${outDir.path}');
if (forceCompile) args.add('--force-compile');
if (htmlOutput) args.add('--html-output');
if (htmlReport) args.add('--html-report');
args.addAll(coerceToPathList(files));
return args;
}
Expand Down
2 changes: 1 addition & 1 deletion lib/src/cli.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import 'singleton.dart' as singleton;
import 'utils.dart';

// This version must be updated in tandem with the pubspec version.
const String appVersion = '0.8.0';
const String appVersion = '0.8.0+1';

List<String> grinderArgs() => _args;
List<String> _args;
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: grinder
# This version must be updated in tandem with the lib/src/cli.dart version.
version: 0.8.0
version: 0.8.0+1
description: Dart workflows, automated.

homepage: https://github.com/google/grinder.dart
Expand Down

0 comments on commit 5903f37

Please sign in to comment.