| Index: packages/initialize/tool/rename_build_outputs.dart
|
| diff --git a/packages/initialize/tool/rename_build_outputs.dart b/packages/initialize/tool/rename_build_outputs.dart
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..56b74945d94234c058cb28f734ace5ede32f8fe8
|
| --- /dev/null
|
| +++ b/packages/initialize/tool/rename_build_outputs.dart
|
| @@ -0,0 +1,21 @@
|
| +library initialize.tool.rename_build_outputs;
|
| +
|
| +import 'dart:io';
|
| +
|
| +import 'package:path/path.dart';
|
| +
|
| +main() {
|
| + var scriptPath = Platform.script.path;
|
| + if (context.style.name == 'windows') scriptPath = scriptPath.substring(1);
|
| + var dir = join(dirname(dirname(scriptPath)), 'build', 'test');
|
| + for (var file in new Directory(dir).listSync()) {
|
| + var filepath = file.path;
|
| + var name = basename(filepath);
|
| + if (name.endsWith('.initialize.dart')) {
|
| + var newPath = join(dirname(filepath),
|
| + name.replaceFirst('.initialize.dart', '.initialize_test.dart'));
|
| + print('Copying $filepath to $newPath');
|
| + new File(filepath).copySync(newPath);
|
| + }
|
| + }
|
| +}
|
|
|