Skip to content

Commit

Permalink
1.2.0 (#12)
Browse files Browse the repository at this point in the history
* deps

* lints

* lints

* lints

* github actions
  • Loading branch information
hoc081098 authored Sep 11, 2021
1 parent d2613b8 commit a8de8c5
Show file tree
Hide file tree
Showing 11 changed files with 80 additions and 46 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/dart.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Dart CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
# Runs at 02:00 UTC on the 1, 4, 7, 10, 13, 16, 19, 22, 25, 28 and 31st of every month.
- cron: "0 2 */3 * *"

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
container: [ 'google/dart:latest', 'google/dart:dev' ]

container:
image: ${{ matrix.container }}

steps:
- uses: actions/checkout@v2

- name: Print Dart version
run: dart --version

- name: Install dependencies
run: pub get

- name: Analyze
run: dart analyze --fatal-infos --fatal-warnings

- name: Format code
run: dart format . --set-exit-if-changed

- name: Active coverage
run: pub global activate coverage

- name: Run tests
run: pub run test test/rx_storage_test.dart --chain-stack-traces

- name: Start Observatory
run: dart --disable-service-auth-codes --enable-vm-service=8111 --pause-isolates-on-exit --enable-asserts test/rx_storage_test.dart &

- name: Collect coverage
run: nohup pub global run coverage:collect_coverage --port=8111 --out=coverage.json --wait-paused --resume-isolates

- name: Format coverage
run: pub global run coverage:format_coverage --lcov --in=coverage.json --out=lcov.info --packages=.packages --report-on=lib

- uses: codecov/[email protected]
31 changes: 0 additions & 31 deletions .travis.yml

This file was deleted.

1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Petrus Nguyễn Thái Học <[email protected]>
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
## 1.2.0 - Sep 11, 2021

- Update dependencies
- `rxdart` to `0.27.2`
- `rxdart_ext` to `0.1.2`
- `meta` to `1.7.0`

- Internal: migrated from `pedantic` to `lints`.

## 1.1.0 - May 9, 2021

- Update `rxdart` to `0.27.0`.
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2020 Flutter-Dart-Open-Source - Petrus Nguyễn Thái Học
Copyright (c) 2020-2021 Flutter-Dart-Open-Source - Petrus Nguyễn Thái Học

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
8 changes: 6 additions & 2 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include: package:pedantic/analysis_options.1.11.0.yaml
include: package:lints/recommended.yaml
analyzer:
strong-mode:
implicit-casts: false
Expand All @@ -7,4 +7,8 @@ linter:
rules:
- public_member_api_docs
- prefer_final_locals
- prefer_relative_imports
- prefer_relative_imports
- always_declare_return_types # https://github.com/dart-lang/lints#migrating-from-packagepedantic
- prefer_single_quotes # https://github.com/dart-lang/lints#migrating-from-packagepedantic
- unawaited_futures # https://github.com/dart-lang/lints#migrating-from-packagepedantic
- unsafe_html # https://github.com/dart-lang/lints#migrating-from-packagepedantic
1 change: 1 addition & 0 deletions example/rx_storage_example.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

2 changes: 1 addition & 1 deletion lib/src/impl/real_storage.dart
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ class RealRxStorage<Key extends Object, Options,
Future<void> dispose() {
assert(_debugAssertNotDisposed());

final dispose = () =>
Future<void> dispose() =>
Future.wait(_writeQueueResources.values.map((q) => q.dispose()))
.then((_) => _writeQueueResources.clear())
.then((_) => _bag.dispose());
Expand Down
11 changes: 5 additions & 6 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: rx_storage
description: Reactive storage for Dart/Flutter. RxDart Storage for Dart/Flutter.
version: 1.1.0
author: Petrus Nguyen Thai Hoc <[email protected]>
version: 1.2.0
homepage: https://github.com/Flutter-Dart-Open-Source/rx_storage.git
repository: https://github.com/Flutter-Dart-Open-Source/rx_storage.git
issue_tracker: https://github.com/Flutter-Dart-Open-Source/rx_storage/issues
Expand All @@ -10,12 +9,12 @@ environment:
sdk: '>=2.12.0 <3.0.0'

dependencies:
rxdart_ext: ^0.1.0
rxdart_ext: ^0.1.2
disposebag: ^1.5.0
meta: ^1.3.0
meta: ^1.7.0
stack_trace: ^1.10.0

dev_dependencies:
pedantic: ^1.11.0
test: ^1.17.3
lints: ^1.0.1
test: ^1.17.12
collection: ^1.15.0
1 change: 0 additions & 1 deletion test/logger/default_logger_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ void main() {
' → { key: key2, type: int, value: 2 }\n',
].join('\n')),
);
;
});

test('OnDataStreamEvent', () {
Expand Down
6 changes: 2 additions & 4 deletions test/storage/streams_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,7 @@ void main() {
await rxStorage.executeUpdate<User>(
'User',
jsonStringToUser, // read
(user) =>
user != null ? user.withName('Transformed ${user.name}') : null,
(user) => user?.withName('Transformed ${user.name}'),
// modify
userToJsonString, // write
);
Expand Down Expand Up @@ -434,8 +433,7 @@ void main() {
rxStorage.executeUpdate<User>(
'User',
jsonStringToUser, // read
(user) =>
user != null ? user.withName('Transformed ${user.name}') : null,
(user) => user?.withName('Transformed ${user.name}'),
// modify
userToJsonString, // write
),
Expand Down

0 comments on commit a8de8c5

Please sign in to comment.