Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(370)

Unified Diff: sdk/lib/_internal/pub_generated/lib/src/package.dart

Issue 599303002: Don't use .gitignore when determining what to build/serve/run. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Use .gitignore in dartdoc validator. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sdk/lib/_internal/pub_generated/lib/src/package.dart
diff --git a/sdk/lib/_internal/pub_generated/lib/src/package.dart b/sdk/lib/_internal/pub_generated/lib/src/package.dart
index 6c04a731fa478607d34196590e13c3c1a58136ae..a497b1e897759d8632d7df3c7c44e9d54fe396e5 100644
--- a/sdk/lib/_internal/pub_generated/lib/src/package.dart
+++ b/sdk/lib/_internal/pub_generated/lib/src/package.dart
@@ -93,7 +93,8 @@ class Package {
static final _WHITELISTED_FILES = const ['.htaccess'];
static final _blacklistedFiles = createFileFilter(['pubspec.lock']);
static final _blacklistedDirs = createDirectoryFilter(['packages']);
- List<String> listFiles({String beneath, recursive: true}) {
+ List<String> listFiles({String beneath, bool recursive: true,
+ bool useGitIgnore: false}) {
if (beneath == null) {
beneath = dir;
} else {
@@ -101,7 +102,7 @@ class Package {
}
if (!dirExists(beneath)) return [];
var files;
- if (git.isInstalled && dirExists(path('.git'))) {
+ if (useGitIgnore && git.isInstalled && dirExists(path('.git'))) {
var relativeBeneath = p.relative(beneath, from: dir);
files = git.runSync(
["ls-files", "--cached", "--others", "--exclude-standard", relativeBeneath],

Powered by Google App Engine
This is Rietveld 408576698