Skip to content

Commit 37314e4

Browse files
committed
remove unused code
1 parent 410dd99 commit 37314e4

File tree

4 files changed

+1
-43
lines changed

4 files changed

+1
-43
lines changed

lib/commons.dart

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
11
part of flutter_automation;
22

33
class _Commons {
4-
static final String scriptRoot =
5-
path.dirname(Platform.script.toFilePath()) + "${path.separator}..";
64
static final String basePath = "./lib";
75
static final String pubspecPath = './pubspec.yaml';
86
static final String stringsPath =
97
"./android/app/src/main/res/values/strings.xml";
108
static final String manifestPath =
119
"./android/app/src/main/AndroidManifest.xml";
1210
static final String appBuildPath = "./android/app/build.gradle";
13-
static final String projectBuildPath = "./android/build.gradle";
1411

1512
/// Default plugin versions
1613
static Map<String, dynamic> defaultConfig = {
@@ -68,41 +65,4 @@ class _Commons {
6865
static List<String> getFileAsLines(String path) {
6966
return File(path).readAsLinesSync();
7067
}
71-
72-
/// Copies files recursively from [from] directory to [to] directory
73-
static void copyFilesRecursive(String from, String to,
74-
{String renameBaseDir}) {
75-
Process.run(
76-
"cp",
77-
["-r", from, to],
78-
).then((res) {
79-
stdout.write(res.stdout);
80-
if (res.stderr.toString().isNotEmpty) {
81-
stderr.write(res.stderr);
82-
} else {
83-
if (renameBaseDir != null) {
84-
renameStockFiles(renameBaseDir);
85-
}
86-
stdout.writeln("copied stock files");
87-
}
88-
});
89-
}
90-
91-
/// Renames all stock files in [basedir]
92-
static void renameStockFiles(String basedir) {
93-
Directory dir = Directory(basedir);
94-
List<FileSystemEntity> files = dir.listSync(recursive: true);
95-
files.forEach((file) {
96-
if (file is File) {
97-
String filename = path.basename(file.path);
98-
if (filename.substring(filename.length - 5, filename.length) ==
99-
".temp") {
100-
String newFilename = filename.substring(0, filename.length - 5);
101-
file.renameSync(
102-
path.dirname(file.path) + path.separator + newFilename);
103-
}
104-
}
105-
});
106-
stdout.writeln("renamed stock files");
107-
}
10868
}

lib/flutter_automation.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import 'dart:io';
55

66
import 'package:args/args.dart';
77
import 'package:http/http.dart' as http;
8-
import 'package:path/path.dart' as path;
98
import 'package:yaml/yaml.dart';
109

1110
part './google_maps.dart';

pubspec.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ packages:
9696
source: hosted
9797
version: "1.3.0"
9898
path:
99-
dependency: "direct main"
99+
dependency: transitive
100100
description:
101101
name: path
102102
url: "https://pub.dartlang.org"

pubspec.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ dependencies:
1313
sdk: flutter
1414
args: ^1.6.0
1515
yaml: ^2.2.1
16-
path: ^1.7.0
1716
http: ^0.12.2
1817

1918
dev_dependencies:

0 commit comments

Comments
 (0)