Skip to content

Commit 11a83b4

Browse files
authored
Merge pull request #301 from SpinlockLabs/fixes
Move to pkg:lints
2 parents 7d811f1 + e91bdd8 commit 11a83b4

33 files changed

+44
-66
lines changed

CHANGELOG.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## 9.0.2
2+
- Switched to use the lints package instead of pedantic https://github.com/SpinlockLabs/github.dart/pull/301
3+
4+
## 9.0.1
5+
- Add `conclusion` property in class `CheckRun`
6+
17
## 9.0.0
28

39
**Breaking change:** In the Gist class, the old type of files was
@@ -15,9 +21,6 @@ Map<String, GistFile>? files;
1521

1622
**Full Changelog**: https://github.com/SpinlockLabs/github.dart/compare/8.5.0...9.0.0
1723

18-
## 9.0.1
19-
- Add `conclusion` property in class `CheckRun`
20-
2124
## 8.5.0
2225

2326
* Adds listing and creating PR Reviews, listing users in an org by @robrbecker in https://github.com/SpinlockLabs/github.dart/pull/287

analysis_options.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
include: package:pedantic/analysis_options.yaml
1+
include: package:lints/recommended.yaml
22

33
analyzer:
44
strong-mode:

example/languages.dart

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import 'dart:html';
22

3-
import 'package:github/github.dart';
43
import 'common.dart';
54

65
DivElement? tableDiv;
@@ -49,15 +48,17 @@ String generateMarkdown(int accuracy) {
4948
final total = totalBytes(breakdown);
5049
final data = breakdown.toList();
5150

52-
var md = '|Name|Bytes|Percentage|\n';
53-
md += '|-----|-----|-----|\n';
51+
var md = StringBuffer('''
52+
|Name|Bytes|Percentage|
53+
|-----|-----|-----|
54+
''');
5455
data.sort((a, b) => b[1].compareTo(a[1]));
5556

56-
data.forEach((info) {
57+
for (final info in data) {
5758
final String? name = info[0];
5859
final int bytes = info[1];
5960
final num percentage = (bytes / total) * 100;
60-
md += '|$name|$bytes|${percentage.toStringAsFixed(accuracy)}|\n';
61-
});
62-
return md;
61+
md.writeln('|$name|$bytes|${percentage.toStringAsFixed(accuracy)}|');
62+
}
63+
return md.toString();
6364
}

example/organization.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import 'dart:async';
22
import 'dart:html';
33

4-
import 'package:github/github.dart';
54
import 'common.dart';
65

76
DivElement? $output;

example/pr.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import 'dart:async';
22
import 'dart:html';
33

4-
import 'package:github/github.dart';
5-
64
import 'common.dart';
75

86
Future<void> main() async {

example/readme.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
import 'dart:html';
22

3-
import 'package:github/github.dart';
4-
53
import 'common.dart';
64

75
Future<void> main() async {

example/releases.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
import 'dart:html';
22

3-
import 'package:github/github.dart';
4-
53
import 'common.dart';
64

75
DivElement? releasesDiv;

example/repos.dart

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import 'dart:async';
22
import 'dart:html';
33

4-
import 'package:github/github.dart';
5-
64
import 'common.dart';
75

86
DivElement? repositoriesDiv;
@@ -29,14 +27,14 @@ Future<void> main() async {
2927
loadRepos();
3028
});
3129

32-
sorts.keys.forEach((name) {
30+
for (final name in sorts.keys) {
3331
querySelector('#sort-$name')!.onClick.listen((event) {
3432
if (_reposCache == null) {
3533
loadRepos(sorts[name]);
3634
}
3735
updateRepos(_reposCache!, sorts[name]);
3836
});
39-
});
37+
}
4038
}
4139

4240
List<Repository>? _reposCache;

example/stars.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import 'dart:html';
22

3-
import 'package:github/github.dart';
43
import 'common.dart';
54

65
DivElement? $stars;

example/user_info.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import 'dart:html';
22

3-
import 'package:github/github.dart';
43
import 'common.dart';
54

65
DivElement? info;

0 commit comments

Comments
 (0)