From f58d261bc53ac0af804777fef8acface502c3fb2 Mon Sep 17 00:00:00 2001 From: Sebastian Wilzbach Date: Mon, 18 Dec 2017 22:02:11 +0100 Subject: [PATCH] Parse dub, dub-registry & dconf.org when --all is used. --- contributors.d | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/contributors.d b/contributors.d index 6c1c6cf..d2c01df 100755 --- a/contributors.d +++ b/contributors.d @@ -57,9 +57,19 @@ auto findAuthors(string revRange, FindConfig config) { Appender!(GitAuthor[]) authors; int commits; - foreach (repo; ["dmd", "druntime", "phobos", "dlang.org", "tools", "installer"] - .map!(r => buildPath(config.cwd, "..", r))) + auto repos = ["dmd", "druntime", "phobos", "dlang.org", "tools", "installer"]; + if (config.showAllContributors) + repos ~= ["dub", "dub-registry", "dconf.org"]; + + foreach (repo; repos.map!(r => buildPath(config.cwd, "..", r))) { + if (!repo.exists) + { + stderr.writefln("Warning: %s doesn't exist. " ~ + "Consider running: git clone https://github.com/dlang/%s ../%2$s", + repo, repo.baseName); + continue; + } if (config.refreshTags) { auto cmd = ["git", "-C", repo, "fetch", "--tags", "https://github.com/dlang/" ~ repo.baseName,