Skip to content

Commit 268d28c

Browse files
committed
deprecate WebRenderer
1 parent 3b09fd9 commit 268d28c

File tree

15 files changed

+170
-52
lines changed

15 files changed

+170
-52
lines changed

.github/dependabot.yml

+16
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,18 @@ version: 2
55
enable-beta-ecosystems: true
66

77
updates:
8+
- package-ecosystem: "pub"
9+
directory: "."
10+
schedule:
11+
interval: "monthly"
812
- package-ecosystem: "pub"
913
directory: "packages/appstore_publish"
1014
schedule:
1115
interval: "monthly"
16+
- package-ecosystem: "pub"
17+
directory: "packages/common_build"
18+
schedule:
19+
interval: "monthly"
1220
- package-ecosystem: "pub"
1321
directory: "packages/firebase_build"
1422
schedule:
@@ -17,6 +25,14 @@ updates:
1725
directory: "packages/firebase_build_menu_flutter"
1826
schedule:
1927
interval: "monthly"
28+
- package-ecosystem: "pub"
29+
directory: "packages/flutter_build"
30+
schedule:
31+
interval: "monthly"
32+
- package-ecosystem: "pub"
33+
directory: "packages/gcr_build"
34+
schedule:
35+
interval: "monthly"
2036
- package-ecosystem: "pub"
2137
directory: "packages/playstore_publish"
2238
schedule:

.github/workflows/run_ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
runs-on: ${{ matrix.os }}
1212
defaults:
1313
run:
14-
working-directory: packages/repo_support
14+
working-directory: .
1515
strategy:
1616
fail-fast: false
1717
matrix:

.github/workflows/run_ci_flutter.yml

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Run CI Flutter
2+
on:
3+
push:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: '0 0 * * 0' # every sunday at midnight
7+
8+
jobs:
9+
test:
10+
name: Test on ${{ matrix.os }} / flutter ${{ matrix.flutter }}
11+
runs-on: ${{ matrix.os }}
12+
defaults:
13+
run:
14+
working-directory: packages/repo_support
15+
strategy:
16+
fail-fast: false
17+
matrix:
18+
include:
19+
- os: ubuntu-latest
20+
flutter: stable
21+
- os: ubuntu-latest
22+
flutter: beta
23+
- os: windows-latest
24+
flutter: stable
25+
- os: macos-latest
26+
flutter: stable
27+
steps:
28+
- uses: actions/checkout@v4
29+
- uses: actions/setup-java@v4
30+
with:
31+
distribution: 'zulu'
32+
java-version: '17.x'
33+
- uses: subosito/flutter-action@v2
34+
with:
35+
channel: ${{ matrix.flutter }}
36+
- run: dart --version
37+
- run: flutter --version
38+
# Setup sqlite3 lib (linux)
39+
- name: Install libsqlite3-dev
40+
run: |
41+
dart pub global activate --source git https://github.com/tekartik/ci.dart --git-path ci --git-ref dart3a
42+
dart pub global run tekartik_ci:setup_sqlite3lib
43+
- run: dart pub get
44+
- run: dart run tool/run_ci_flutter.dart

packages/appstore_publish/pubspec.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ version: 0.1.1
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
# Add regular dependencies here.
1010
dependencies:
11-
process_run: '>=0.14.1+3'
11+
process_run: ">=1.2.1+1"
1212
tekartik_common_utils:
1313
git:
1414
url: https://github.com/tekartik/common_utils.dart
1515
ref: dart3a
1616

1717
dev_dependencies:
18-
lints: '>=2.0.0'
19-
test: '>=1.21.0'
18+
lints: ">=5.0.0"
19+
test: ">=1.24.0"

packages/common_build/pubspec.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,17 @@ version: 1.0.0
44
publish_to: none;
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
# Add regular dependencies here.
1010
dependencies:
11-
dev_build: '>=1.0.0+14'
12-
process_run: '>=1.2.0'
13-
path: '>=1.8.0'
14-
fs_shim: '>=2.3.2+3'
11+
dev_build: ">=1.1.0+2"
12+
process_run: ">=1.2.1+1"
13+
path: ">=1.9.0"
14+
fs_shim: ">=2.3.3+1"
1515

1616
dev_dependencies:
17-
lints: '>=4.0.0'
17+
lints: ">=5.0.0"
1818
tekartik_lints:
1919
git:
2020
url: https://github.com/tekartik/common.dart

packages/firebase_build/pubspec.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ version: 0.2.0
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
dependencies:
10-
cv: '>=1.0.0'
11-
path: '>=1.7.0'
12-
process_run: '>=0.10.2'
13-
dev_build: '>=0.1.0'
10+
cv: ">=1.1.0+4"
11+
path: ">=1.9.0"
12+
process_run: ">=1.2.1+1"
13+
dev_build: ">=1.1.0+2"
1414
tekartik_flutter_build:
1515
git:
1616
url: https://github.com/tekartik/app_build.dart
@@ -41,7 +41,7 @@ dependencies:
4141
url: https://github.com/tekartik/common_utils.dart
4242
ref: dart3a
4343
dev_dependencies:
44-
test: '>=1.14.4'
44+
test: ">=1.24.0"
4545

4646
dependency_overrides:
4747
tekartik_web_publish:

packages/firebase_build_menu_flutter/pubspec.yaml

+7-7
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ version: 0.3.4
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
dependencies:
10-
path: '>=1.6.0'
11-
dev_build: '>=0.1.0'
12-
process_run: '>=0.10.2'
13-
args: '>=2.4.2'
10+
path: ">=1.9.0"
11+
dev_build: ">=1.1.0+2"
12+
process_run: ">=1.2.1+1"
13+
args: ">=2.6.0"
1414
tekartik_firebase_build:
1515
git:
1616
url: https://github.com/tekartik/app_build.dart
@@ -48,8 +48,8 @@ dependencies:
4848
version: '>=0.1.0'
4949

5050
dev_dependencies:
51-
lints: '>=1.0.0'
52-
test: '>=1.16.0'
51+
lints: ">=5.0.0"
52+
test: ">=1.24.0"
5353

5454
dependency_overrides:
5555
tekartik_firebase_build:

packages/flutter_build/lib/src/app_build.dart

+5-5
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ String _fixFolder(String path, String folder) {
1717
/// Web rendered (html deprecated
1818
enum FlutterWebRenderer {
1919
/// Deprecated
20+
@Deprecated('no longer supported')
2021
html,
2122

2223
/// Default
@@ -132,9 +133,9 @@ class FlutterWebAppBuilder implements CommonAppBuilder {
132133
Future<void> buildOnly() async {
133134
var buildOptions = options.buildOptions;
134135
var shell = _shell;
135-
var renderOptions = '';
136+
// var renderOptions = '';
136137
var wasm = buildOptions?.wasm ?? false;
137-
if (!wasm) {
138+
/*if (!wasm) {
138139
// not compatible with wasm
139140
switch (buildOptions?.renderer) {
140141
case FlutterWebRenderer.html:
@@ -145,14 +146,13 @@ class FlutterWebAppBuilder implements CommonAppBuilder {
145146
break;
146147
default:
147148
}
148-
}
149+
}*/
149150
var wasmOptions = wasm ? ' --wasm' : '';
150151
var targetOptions = '';
151152
if (buildOptions?.target != null) {
152153
targetOptions = ' --target ${buildOptions!.target}';
153154
}
154-
await shell
155-
.run('flutter build web$renderOptions$wasmOptions$targetOptions');
155+
await shell.run('flutter build web$wasmOptions$targetOptions');
156156
}
157157

158158
/// Copy to deploy using deploy.yaml

packages/flutter_build/pubspec.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version: 0.2.0
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
dependencies:
1010
path: ">=1.9.0"
@@ -37,4 +37,4 @@ dependency_overrides:
3737
tekartik_web_publish:
3838
path: ../web_publish
3939
tekartik_common_build:
40-
path: ../common_build
40+
path: ../common_build
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
@TestOn('vm')
2+
library;
3+
4+
import 'dart:io';
5+
6+
import 'package:dev_build/shell.dart';
7+
import 'package:path/path.dart';
8+
import 'package:tekartik_flutter_build/app_build.dart';
9+
import 'package:test/test.dart';
10+
11+
var _createdOnce = false;
12+
Future<void> main() async {
13+
var path = join('.dart_tool', 'tekartik_build_flutter', 'test', 'app1');
14+
group('flutter_build', () {
15+
Future<void> createProject({bool? force}) async {
16+
if (!_createdOnce && (force == true || !Directory(path).existsSync())) {
17+
var shell = Shell(workingDirectory: path);
18+
Directory(path).createSync(recursive: true);
19+
await shell.run('flutter create .');
20+
_createdOnce = true;
21+
}
22+
}
23+
24+
setUpAll(() async {
25+
await createProject();
26+
});
27+
test('build web', () async {
28+
var builder = FlutterWebAppBuilder(
29+
options: FlutterWebAppOptions(
30+
path: path,
31+
buildOptions: FlutterWebAppBuildOptions(
32+
renderer: FlutterWebRenderer.canvasKit)));
33+
await builder.buildOnly();
34+
});
35+
test('build wasm', () async {
36+
var builder = FlutterWebAppBuilder(
37+
options: FlutterWebAppOptions(
38+
path: path, buildOptions: FlutterWebAppBuildOptions(wasm: true)));
39+
await builder.buildOnly();
40+
});
41+
}, skip: !isFlutterSupportedSync);
42+
}

packages/gcr_build/pubspec.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,17 @@ version: 1.0.0
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
# Add regular dependencies here.
1010
dependencies:
11-
path:
11+
path: ">=1.9.0"
1212
tekartik_common_utils:
1313
git:
1414
url: https://github.com/tekartik/common_utils.dart
1515
ref: dart3a
16-
dev_build: ">=1.0.1"
17-
process_run: ">=1.2.1"
16+
dev_build: ">=1.1.0+2"
17+
process_run: ">=1.2.1+1"
1818
tekartik_common_build:
1919
git:
2020
url: https://github.com/tekartik/app_build.dart

packages/playstore_publish/pubspec.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ version: 0.2.0
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
resolution: workspace
1010
# Add regular dependencies here.
1111
dependencies:
12-
path: '>=1.6.0'
13-
args: '>=2.4.2'
12+
path: ">=1.9.0"
13+
args: ">=2.6.0"
1414
googleapis: '>=12.0.0'
1515
googleapis_auth: '>=1.4.1'
16-
process_run: '>=1.2.0'
16+
process_run: ">=1.2.1+1"
1717
tekartik_io_auth_utils:
1818
git:
1919
url: https://github.com/tekartik/io_auth_utils.dart
@@ -24,5 +24,5 @@ dependencies:
2424
ref: dart3a
2525
version: '>=0.1.0'
2626
dev_dependencies:
27-
lints: '>=2.0.0'
28-
test: '>=1.21.0'
27+
lints: ">=5.0.0"
28+
test: ">=1.24.0"

packages/repo_support/pubspec.yaml

+7-7
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version: 0.2.0
44
publish_to: none
55

66
environment:
7-
sdk: ^3.5.0
7+
sdk: ^3.6.0
88

99
dev_dependencies:
1010
tekartik_lints:
@@ -13,9 +13,9 @@ dev_dependencies:
1313
ref: dart3a
1414
path: packages/lints
1515
version: '>=0.1.0'
16-
path: '>=1.6.0'
17-
pub_semver: '>=1.4.0'
18-
process_run: '>=0.10.3'
19-
test: '>=1.16.0'
20-
dev_build: '>=0.1.0'
21-
lints: '>=2.0.0'
16+
path: ">=1.9.0"
17+
pub_semver: ">=2.1.4"
18+
process_run: ">=1.2.1+1"
19+
test: ">=1.24.0"
20+
dev_build: ">=1.1.0+2"
21+
lints: ">=5.0.0"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import 'package:dev_build/menu/menu_run_ci.dart';
2+
import 'package:dev_build/shell.dart';
3+
import 'package:path/path.dart';
4+
import 'package:test/test.dart';
5+
6+
Future<void> main(List<String> args) async {
7+
var topPackagesPath = '..';
8+
var path = join(topPackagesPath, 'flutter_build');
9+
test('build_web_test', () async {
10+
var shell = Shell(workingDirectory: path);
11+
var prj = PubIoPackage(path);
12+
await prj.ready;
13+
await prj.pubGet();
14+
await shell.run('dart test test/build_web_test.dart');
15+
});
16+
}

0 commit comments

Comments
 (0)