Fix init
bug
This commit is contained in:
parent
efce4496fc
commit
63e5c99c96
3 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
|||
# 2.1.7+1
|
||||
* Fix a bug where new directories were not being created in
|
||||
`init`.
|
||||
|
||||
# 2.1.7
|
||||
* Fix a bug where `ArgResults.arguments` was used in `init` instead of the
|
||||
intended `ArgResults.rest`.
|
||||
|
|
|
@ -35,11 +35,12 @@ Future<void> copyDirectory(Directory source, Directory destination) async {
|
|||
if (entity is Directory) {
|
||||
var newDirectory =
|
||||
Directory(p.join(destination.absolute.path, p.basename(entity.path)));
|
||||
await newDirectory.create();
|
||||
await newDirectory.create(recursive: true);
|
||||
await copyDirectory(entity.absolute, newDirectory);
|
||||
} else if (entity is File) {
|
||||
var newPath = p.join(destination.path, p.basename(entity.path));
|
||||
// print(darkGray.wrap('\rCopying file "${entity.path}" -> "$newPath"'));
|
||||
await File(newPath).create(recursive: true);
|
||||
await entity.copy(newPath);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@ author: Tobe O <thosakwe@gmail.com>
|
|||
description: Command-line tools for the Angel framework, including scaffolding.
|
||||
homepage: https://github.com/angel-dart/angel_cli
|
||||
name: angel_cli
|
||||
version: 2.1.7
|
||||
version: 2.1.7+1
|
||||
dependencies:
|
||||
analyzer: ">=0.32.0 <2.0.0"
|
||||
args: ^1.0.0
|
||||
|
|
Loading…
Reference in a new issue