flutter packages update
This commit is contained in:
parent
4ddf9b763b
commit
b83408b976
@ -6,26 +6,28 @@ let
|
||||
let files = builtins.attrNames (builtins.readDir dir);
|
||||
in map (f: dir + ("/" + f)) files;
|
||||
in {
|
||||
stable = mkFlutter {
|
||||
stable = mkFlutter rec {
|
||||
pname = "flutter";
|
||||
channel = "stable";
|
||||
version = "1.12.13+hotfix.9";
|
||||
sha256Hash = "1ql3zvmmk5zk47y30lajxaam04q6vr373dayq15jv4vpc0fzif1y";
|
||||
version = "1.17.3";
|
||||
filename = "flutter_linux_${version}-${channel}.tar.xz";
|
||||
sha256Hash = "16ymnphah0xqf9vn44syznmr66xbkdh4y75ynk7nr8aisrcdd81z";
|
||||
patches = getPatches ./patches/stable;
|
||||
};
|
||||
beta = mkFlutter {
|
||||
beta = mkFlutter rec {
|
||||
pname = "flutter-beta";
|
||||
channel = "beta";
|
||||
version = "1.15.17";
|
||||
sha256Hash = "0iil6y6y477dhjgzx54ab5m9nj0jg4xl8x4zzd9iwh8m756r7qsd";
|
||||
version = "1.19.0-4.1.pre";
|
||||
filename = "flutter_linux_${version}-${channel}.tar.xz";
|
||||
sha256Hash = "002aprwjx7wd79dy6rb61knddb8n23gwa5z8a9dydv0igjw50r32";
|
||||
patches = getPatches ./patches/beta;
|
||||
};
|
||||
dev = mkFlutter rec {
|
||||
pname = "flutter-dev";
|
||||
channel = "dev";
|
||||
version = "1.17.0-dev.5.0";
|
||||
version = "1.20.0-0.0.pre";
|
||||
filename = "flutter_linux_${version}-${channel}.tar.xz";
|
||||
sha256Hash = "0ks2jf2bd42y2jsc91p33r57q7j3m94d8ihkmlxzwi53x1mwp0pk";
|
||||
sha256Hash = "1gjsvsw9wnfcip1hcm0dksgyp23jnvfl98gzj1dl1gyrqdrmj15b";
|
||||
patches = getPatches ./patches/beta;
|
||||
};
|
||||
}
|
||||
|
@ -1,24 +1,11 @@
|
||||
diff --git a/bin/flutter b/bin/flutter
|
||||
index e0c18e235..2c3fb7ddd 100755
|
||||
--- a/bin/flutter
|
||||
+++ b/bin/flutter
|
||||
@@ -185,8 +185,6 @@ fi
|
||||
# FLUTTER_TOOL_ARGS="--enable-asserts $FLUTTER_TOOL_ARGS"
|
||||
# FLUTTER_TOOL_ARGS="$FLUTTER_TOOL_ARGS --observe=65432"
|
||||
|
||||
-(upgrade_flutter) 3< "$PROG_NAME"
|
||||
-
|
||||
# FLUTTER_TOOL_ARGS isn't quoted below, because it is meant to be considered as
|
||||
# separate space-separated args.
|
||||
"$DART" --packages="$FLUTTER_TOOLS_DIR/.packages" $FLUTTER_TOOL_ARGS "$SNAPSHOT_PATH" "$@"
|
||||
diff --git a/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart b/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
index 99455ae64..f5b0cb59c 100644
|
||||
index 21be933e1..2ea73c4c0 100644
|
||||
--- a/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
+++ b/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
@@ -301,13 +301,6 @@ class FlutterCommandRunner extends CommandRunner<void> {
|
||||
@@ -294,13 +294,6 @@ class FlutterCommandRunner extends CommandRunner<void> {
|
||||
globals.flutterUsage.suppressAnalytics = true;
|
||||
}
|
||||
|
||||
_checkFlutterCopy();
|
||||
- try {
|
||||
- await globals.flutterVersion.ensureVersionFile();
|
||||
- } on FileSystemException catch (e) {
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/dev/devicelab/lib/framework/runner.dart b/dev/devicelab/lib/framework/runner.dart
|
||||
index 8e511eefd..fbc7d6ac3 100644
|
||||
index 8e511eefd..fef3cca8b 100644
|
||||
--- a/dev/devicelab/lib/framework/runner.dart
|
||||
+++ b/dev/devicelab/lib/framework/runner.dart
|
||||
@@ -126,7 +126,7 @@ Future<void> cleanupSystem() async {
|
||||
@ -12,31 +12,31 @@ index 8e511eefd..fbc7d6ac3 100644
|
||||
if (!Platform.isWindows) {
|
||||
await exec(
|
||||
diff --git a/packages/flutter_tools/lib/src/asset.dart b/packages/flutter_tools/lib/src/asset.dart
|
||||
index 79b06949f..9040ba0a8 100644
|
||||
index c680de599..480abfb77 100644
|
||||
--- a/packages/flutter_tools/lib/src/asset.dart
|
||||
+++ b/packages/flutter_tools/lib/src/asset.dart
|
||||
@@ -6,6 +6,7 @@ import 'dart:async';
|
||||
|
||||
@@ -8,6 +8,7 @@ import 'package:meta/meta.dart';
|
||||
import 'package:package_config/package_config.dart';
|
||||
import 'package:yaml/yaml.dart';
|
||||
|
||||
+import 'base/common.dart';
|
||||
import 'base/context.dart';
|
||||
import 'base/file_system.dart';
|
||||
import 'base/utils.dart';
|
||||
@@ -325,7 +326,7 @@ List<_Asset> _getMaterialAssets(String fontSet) {
|
||||
for (final Map<dynamic, dynamic> font in family['fonts']) {
|
||||
@@ -392,7 +393,7 @@ List<_Asset> _getMaterialAssets(String fontSet) {
|
||||
for (final Map<dynamic, dynamic> font in (family['fonts'] as List<dynamic>).cast<Map<dynamic, dynamic>>()) {
|
||||
final Uri entryUri = globals.fs.path.toUri(font['asset'] as String);
|
||||
result.add(_Asset(
|
||||
- baseDir: globals.fs.path.join(Cache.flutterRoot, 'bin', 'cache', 'artifacts', 'material_fonts'),
|
||||
+ baseDir: globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'artifacts', 'material_fonts'),
|
||||
+ baseDir: globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'artifacts', 'material_fonts'),
|
||||
relativeUri: Uri(path: entryUri.pathSegments.last),
|
||||
entryUri: entryUri,
|
||||
));
|
||||
package: null,
|
||||
diff --git a/packages/flutter_tools/lib/src/cache.dart b/packages/flutter_tools/lib/src/cache.dart
|
||||
index 715189938..5afb2a0db 100644
|
||||
index c0946782c..bdbc35cb8 100644
|
||||
--- a/packages/flutter_tools/lib/src/cache.dart
|
||||
+++ b/packages/flutter_tools/lib/src/cache.dart
|
||||
@@ -189,8 +189,14 @@ class Cache {
|
||||
@@ -202,8 +202,15 @@ class Cache {
|
||||
return;
|
||||
}
|
||||
assert(_lock == null);
|
||||
@ -46,13 +46,14 @@ index 715189938..5afb2a0db 100644
|
||||
+ dir.createSync(recursive: true);
|
||||
+ globals.os.chmod(dir, '755');
|
||||
+ }
|
||||
+
|
||||
final File lockFile =
|
||||
- globals.fs.file(globals.fs.path.join(flutterRoot, 'bin', 'cache', 'lockfile'));
|
||||
+ globals.fs.file(globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'lockfile'));
|
||||
try {
|
||||
_lock = lockFile.openSync(mode: FileMode.write);
|
||||
} on FileSystemException catch (e) {
|
||||
@@ -290,7 +296,7 @@ class Cache {
|
||||
@@ -306,7 +313,7 @@ class Cache {
|
||||
if (_rootOverride != null) {
|
||||
return _fileSystem.directory(_fileSystem.path.join(_rootOverride.path, 'bin', 'cache'));
|
||||
} else {
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/bin/flutter b/bin/flutter
|
||||
index 3955f8f39..1e7573d30 100755
|
||||
index cdf974233..1f7de1c1b 100755
|
||||
--- a/bin/flutter
|
||||
+++ b/bin/flutter
|
||||
@@ -185,8 +185,6 @@ fi
|
||||
@ -12,20 +12,20 @@ index 3955f8f39..1e7573d30 100755
|
||||
# separate space-separated args.
|
||||
"$DART" --packages="$FLUTTER_TOOLS_DIR/.packages" $FLUTTER_TOOL_ARGS "$SNAPSHOT_PATH" "$@"
|
||||
diff --git a/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart b/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
index 5e45819d9..ab748b059 100644
|
||||
index b3e69714f..a9eb76234 100644
|
||||
--- a/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
+++ b/packages/flutter_tools/lib/src/runner/flutter_command_runner.dart
|
||||
@@ -377,13 +377,6 @@ class FlutterCommandRunner extends CommandRunner<void> {
|
||||
@@ -301,13 +301,6 @@ class FlutterCommandRunner extends CommandRunner<void> {
|
||||
}
|
||||
|
||||
_checkFlutterCopy();
|
||||
- try {
|
||||
- await FlutterVersion.instance.ensureVersionFile();
|
||||
- await globals.flutterVersion.ensureVersionFile();
|
||||
- } on FileSystemException catch (e) {
|
||||
- printError('Failed to write the version file to the artifact cache: "$e".');
|
||||
- printError('Please ensure you have permissions in the artifact cache directory.');
|
||||
- globals.printError('Failed to write the version file to the artifact cache: "$e".');
|
||||
- globals.printError('Please ensure you have permissions in the artifact cache directory.');
|
||||
- throwToolExit('Failed to write the version file');
|
||||
- }
|
||||
if (topLevelResults.command?.name != 'upgrade' && topLevelResults['version-check'] as bool) {
|
||||
await FlutterVersion.instance.checkFlutterVersionFreshness();
|
||||
}
|
||||
final bool machineFlag = topLevelResults['machine'] as bool;
|
||||
if (topLevelResults.command?.name != 'upgrade' && topLevelResults['version-check'] as bool && !machineFlag) {
|
||||
await globals.flutterVersion.checkFlutterVersionFreshness();
|
||||
|
@ -1,5 +1,5 @@
|
||||
diff --git a/dev/devicelab/lib/framework/runner.dart b/dev/devicelab/lib/framework/runner.dart
|
||||
index 9fae74726..d88d6ecbb 100644
|
||||
index 8e511eefd..fef3cca8b 100644
|
||||
--- a/dev/devicelab/lib/framework/runner.dart
|
||||
+++ b/dev/devicelab/lib/framework/runner.dart
|
||||
@@ -126,7 +126,7 @@ Future<void> cleanupSystem() async {
|
||||
@ -7,57 +7,58 @@ index 9fae74726..d88d6ecbb 100644
|
||||
final String gradlewBinaryName = Platform.isWindows ? 'gradlew.bat' : 'gradlew';
|
||||
final Directory tempDir = Directory.systemTemp.createTempSync('flutter_devicelab_shutdown_gradle.');
|
||||
- recursiveCopy(Directory(path.join(flutterDirectory.path, 'bin', 'cache', 'artifacts', 'gradle_wrapper')), tempDir);
|
||||
+ recursiveCopy(Directory(path.join(homeDirPath, '.cache', 'flutter', 'artifacts', 'gradle_wrapper')), tempDir);
|
||||
+ recursiveCopy(Directory(path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'artifacts', 'gradle_wrapper')), tempDir);
|
||||
copy(File(path.join(path.join(flutterDirectory.path, 'packages', 'flutter_tools'), 'templates', 'app', 'android.tmpl', 'gradle', 'wrapper', 'gradle-wrapper.properties')), Directory(path.join(tempDir.path, 'gradle', 'wrapper')));
|
||||
if (!Platform.isWindows) {
|
||||
await exec(
|
||||
diff --git a/packages/flutter_tools/lib/src/asset.dart b/packages/flutter_tools/lib/src/asset.dart
|
||||
index e6216c737..5ab497092 100644
|
||||
index c680de599..480abfb77 100644
|
||||
--- a/packages/flutter_tools/lib/src/asset.dart
|
||||
+++ b/packages/flutter_tools/lib/src/asset.dart
|
||||
@@ -6,6 +6,7 @@ import 'dart:async';
|
||||
|
||||
@@ -8,6 +8,7 @@ import 'package:meta/meta.dart';
|
||||
import 'package:package_config/package_config.dart';
|
||||
import 'package:yaml/yaml.dart';
|
||||
|
||||
+import 'base/common.dart';
|
||||
import 'base/context.dart';
|
||||
import 'base/file_system.dart';
|
||||
import 'base/platform.dart';
|
||||
@@ -326,7 +327,7 @@ List<_Asset> _getMaterialAssets(String fontSet) {
|
||||
for (Map<dynamic, dynamic> font in family['fonts']) {
|
||||
final Uri entryUri = fs.path.toUri(font['asset'] as String);
|
||||
import 'base/utils.dart';
|
||||
@@ -392,7 +393,7 @@ List<_Asset> _getMaterialAssets(String fontSet) {
|
||||
for (final Map<dynamic, dynamic> font in (family['fonts'] as List<dynamic>).cast<Map<dynamic, dynamic>>()) {
|
||||
final Uri entryUri = globals.fs.path.toUri(font['asset'] as String);
|
||||
result.add(_Asset(
|
||||
- baseDir: fs.path.join(Cache.flutterRoot, 'bin', 'cache', 'artifacts', 'material_fonts'),
|
||||
+ baseDir: fs.path.join(homeDirPath, '.cache', 'flutter', 'artifacts', 'material_fonts'),
|
||||
- baseDir: globals.fs.path.join(Cache.flutterRoot, 'bin', 'cache', 'artifacts', 'material_fonts'),
|
||||
+ baseDir: globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'artifacts', 'material_fonts'),
|
||||
relativeUri: Uri(path: entryUri.pathSegments.last),
|
||||
entryUri: entryUri,
|
||||
));
|
||||
package: null,
|
||||
diff --git a/packages/flutter_tools/lib/src/cache.dart b/packages/flutter_tools/lib/src/cache.dart
|
||||
index 5e1950b56..45585f9c0 100644
|
||||
index c0946782c..bdbc35cb8 100644
|
||||
--- a/packages/flutter_tools/lib/src/cache.dart
|
||||
+++ b/packages/flutter_tools/lib/src/cache.dart
|
||||
@@ -164,8 +164,14 @@ class Cache {
|
||||
@@ -202,8 +202,15 @@ class Cache {
|
||||
return;
|
||||
}
|
||||
assert(_lock == null);
|
||||
+
|
||||
+ final Directory dir = fs.directory(fs.path.join(homeDirPath, '.cache', 'flutter'));
|
||||
+ final Directory dir = globals.fs.directory(globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter'));
|
||||
+ if (!dir.existsSync()) {
|
||||
+ dir.createSync(recursive: true);
|
||||
+ os.chmod(dir, '755');
|
||||
+ globals.os.chmod(dir, '755');
|
||||
+ }
|
||||
+
|
||||
final File lockFile =
|
||||
- fs.file(fs.path.join(flutterRoot, 'bin', 'cache', 'lockfile'));
|
||||
+ fs.file(fs.path.join(homeDirPath, '.cache', 'flutter', 'lockfile'));
|
||||
- globals.fs.file(globals.fs.path.join(flutterRoot, 'bin', 'cache', 'lockfile'));
|
||||
+ globals.fs.file(globals.fs.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter', 'lockfile'));
|
||||
try {
|
||||
_lock = lockFile.openSync(mode: FileMode.write);
|
||||
} on FileSystemException catch (e) {
|
||||
@@ -239,7 +245,7 @@ class Cache {
|
||||
@@ -306,7 +313,7 @@ class Cache {
|
||||
if (_rootOverride != null) {
|
||||
return fs.directory(fs.path.join(_rootOverride.path, 'bin', 'cache'));
|
||||
return _fileSystem.directory(_fileSystem.path.join(_rootOverride.path, 'bin', 'cache'));
|
||||
} else {
|
||||
- return fs.directory(fs.path.join(flutterRoot, 'bin', 'cache'));
|
||||
+ return fs.directory(fs.path.join(homeDirPath, '.cache', 'flutter'));
|
||||
- return _fileSystem.directory(_fileSystem.path.join(flutterRoot, 'bin', 'cache'));
|
||||
+ return _fileSystem.directory(_fileSystem.path.join(globals.fsUtils.homeDirPath, '.cache', 'flutter'));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user