File tree Expand file tree Collapse file tree 7 files changed +39
-31
lines changed Expand file tree Collapse file tree 7 files changed +39
-31
lines changed Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -28,3 +28,4 @@ migrate_working_dir/
28
28
.dart_tool /
29
29
.packages
30
30
build /
31
+ .flutter-plugins-dependencies
Original file line number Diff line number Diff line change 1
- ## 0.0.4
1
+ ## 0.0.5
2
2
3
3
- Add ` value ` setter.
Original file line number Diff line number Diff line change 1
1
name : local_file_preferences
2
2
description : This package provides local json file saving and Loading utility.
3
- version : 0.0.3
3
+ version : 0.0.5
4
4
homepage : https://mj-studio-library.github.io/flutter-local-file-preferences/
5
5
repository : https://github.com/mj-studio-library/flutter-local-file-preferences
6
6
Original file line number Diff line number Diff line change 1
1
import 'dart:io' ;
2
+
2
3
import 'package:yaml/yaml.dart' ;
3
4
4
5
// ignore_for_file: avoid_print
@@ -12,16 +13,13 @@ void main(List<String> args) {
12
13
var tagVersion = '' ;
13
14
if (args.isNotEmpty) {
14
15
tagVersion = args[0 ].split ('/' ).last;
16
+ } else {
17
+ throw Exception ();
15
18
}
16
19
if (tagVersion.startsWith ('v' )) {
17
20
tagVersion = tagVersion.substring (1 );
18
21
}
19
22
20
- if (pubspecVersion != tagVersion) {
21
- throw Exception (
22
- 'pubspec version ($pubspecVersion ) and tag version ($tagVersion ) are different' );
23
- }
24
-
25
23
String changeLog = File ('CHANGELOG.md' ).readAsStringSync ();
26
24
if (! changeLog.startsWith ('## $tagVersion ' )) {
27
25
throw Exception (
Original file line number Diff line number Diff line change
1
+ fail () {
2
+ echo " ERROR: ${1} "
3
+ exit 1
4
+ }
5
+
6
+ tag=$1
7
+
8
+ if [[ -z $tag ]]; then
9
+ fail ' arg fail'
10
+ fi
11
+
12
+ flutter pub get
13
+ if [[ $? -ne 0 ]]; then
14
+ fail ' fail'
15
+ fi
16
+ flutter pub run tool/publish/check_version.dart $tag
17
+ if [[ $? -ne 0 ]]; then
18
+ fail ' fail'
19
+ fi
20
+ flutter analyze
21
+ if [[ $? -ne 0 ]]; then
22
+ fail ' fail'
23
+ fi
24
+ dart format --set-exit-if-changed .
25
+ if [[ $? -ne 0 ]]; then
26
+ fail ' fail'
27
+ fi
28
+ flutter pub publish --force
29
+ if [[ $? -ne 0 ]]; then
30
+ fail ' fail'
31
+ fi
32
+ git tag $tag
33
+ git push origin $tag
You can’t perform that action at this time.
0 commit comments