Skip to content
This repository was archived by the owner on Nov 1, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## 0.3.0-nullsafety
## 0.3.0-nullsafety.0

- Updated to support 2.12.0 and null safety.

## 0.2.1
Expand Down
17 changes: 6 additions & 11 deletions lib/cli_logging.dart
Original file line number Diff line number Diff line change
Expand Up @@ -201,16 +201,13 @@ class AnsiProgress extends Progress {
final Ansi ansi;

int _index = 0;
late Timer _timer;
late final _timer = Timer.periodic(Duration(milliseconds: 80), (t) {
_index++;
_updateDisplay();
});

AnsiProgress(this.ansi, String message) : super(message) {
io.stdout.write('${message}... '.padRight(40));

_timer = Timer.periodic(Duration(milliseconds: 80), (t) {
_index++;
_updateDisplay();
});

_updateDisplay();
}

Expand Down Expand Up @@ -258,12 +255,10 @@ class VerboseLogger implements Logger {
@override
Ansi ansi;
bool logTime;
late Stopwatch _timer;
final _timer = Stopwatch()..start();

VerboseLogger({Ansi? ansi, this.logTime = false})
: ansi = ansi ?? Ansi(Ansi.terminalSupportsAnsi) {
_timer = Stopwatch()..start();
}
: ansi = ansi ?? Ansi(Ansi.terminalSupportsAnsi);

@override
bool get isVerbose => true;
Expand Down