Commit Graph

16 Commits

Author SHA1 Message Date
Anders Kaseorg e08a24e47f ruff: Fix UP006 Use `list` instead of `List` for type annotation.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-07-13 22:28:22 -07:00
Anders Kaseorg 8e9ead2575 ruff: Fix FURB177 Prefer `Path.cwd()` over `Path().resolve()`.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-06-30 22:37:15 -07:00
Anders Kaseorg 835ee69c80 docs: Fix grammar errors found by mwic.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-09 13:24:09 -07:00
Greg Price 2baa4fc0ca total-contributions: Add zulip-flutter to the list of repos. 2023-05-22 16:04:26 -07:00
Greg Price c4cc27cd20 total-contributions: Fix bug that replaced a repo's whole history with nothing.
When using a start date before the first commit to a repo, we should
include the repo's entire history (up to the end date) in our totals.

Instead, we were using a range like "..{upper_version}", which in Git
revision-range syntax means the start of the range is HEAD -- so the
range was empty.

Fix that by leaving out the ".." when we want no left endpoint.
2023-05-22 16:04:26 -07:00
Greg Price 0c8fef2fc8 total-contributions: Factor out logic common to all repos. 2023-05-22 16:04:26 -07:00
Anders Kaseorg df001db1a9 black: Reformat with Black 23.
Black 23 enforces some slightly more specific rules about empty line
counts and redundant parenthesis removal, but the result is still
compatible with Black 22.

(This does not actually upgrade our Python environment to Black 23
yet.)

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-02-02 10:40:13 -08:00
Tim Abbott 8023a646de tools: Update source repos in total-contributions.
Otherwise, the output will incorrectly exclude any new commits in
repositories you'd used this tool with previously.
2022-10-31 16:27:31 -07:00
Tim Abbott 8b352e9321 total-contributions: Fix broken pathlib/os.path combination.
This is still messy, in that it does the `chdir` using a different
library than the rest, but it's at least more consistent with the
codebase and it should be possible to bulk migrate the `ZULIP_PATH`
calculation, which we have in a dozen files, to pathlib later.
2022-10-31 16:15:38 -07:00
Tim Abbott d9bf8baca1 tools: Add per-repository commit counts in contributions tool.
This makes the output nice enough to include in the blog post.
2022-03-29 14:13:17 -07:00
Tim Abbott 13da2c2fb7 total-contributions: Clone repositories if already available.
This makes it more convenient to manage.
2022-03-28 23:01:58 -07:00
Tim Abbott a7f13ba723 total-contributions: Support all repositories and improve output. 2022-03-28 23:01:58 -07:00
Tim Abbott 7cbe9665b6 total-contributions: Exclude dependabot commits. 2022-03-28 23:01:58 -07:00
Tim Abbott a234fe9c4c total-contributions: Use commits by date, not by release. 2022-03-28 23:01:58 -07:00
Tim Abbott 6b5ce3579c total-contributions: Do a fetch for zulip/zulip as well.
This avoids producing stale output by having a consistent algorithm
for all repositories.
2022-03-28 23:01:58 -07:00
Abhishek Reddypalle cab37b4aca tools: Add tool to count contributions across all major repositories.
This will allow Zulip release announcements to credit contributions
made to Zulip projects beyond the server in our release announcements.

Fixes #19044.
2022-03-23 14:20:30 -07:00