| Index: utils/pub/git_source.dart
|
| diff --git a/utils/pub/git_source.dart b/utils/pub/git_source.dart
|
| index 7f59d8941e9a15b578e2cd6bc6d9fd3ba9cda2ba..a815feb2c7638dc47abaaf70223c5cb4524fb957 100644
|
| --- a/utils/pub/git_source.dart
|
| +++ b/utils/pub/git_source.dart
|
| @@ -64,8 +64,10 @@ class GitSource extends Source {
|
| * The package name of a Git repo is the name of the directory into which
|
| * it'll be cloned.
|
| */
|
| - String packageName(description) =>
|
| - basename(_getUrl(description)).replaceFirst(const RegExp("\.git\$"), "");
|
| + String packageName(description) {
|
| + return basename(_getUrl(description)
|
| + .replaceFirst(const RegExp(@"(\.git)?/?$"), ""));
|
| + }
|
|
|
| /**
|
| * Ensures [description] is a Git URL.
|
|
|