From: Tom de Vries <tdevries@suse.de>
To: gdb-patches@sourceware.org
Subject: [pushed] [pre-commit] Use pass_filenames=false for pre-commit-setup
Date: Wed, 17 Jun 2026 00:36:31 +0200 [thread overview]
Message-ID: <20260616223631.3456338-1-tdevries@suse.de> (raw)
I came across pre-commit setting pass_filenames, and realized we can use it
for the pre-commit-setup hook.
It saves about half a second for an all-files run. Before:
...
$ ( time pre-commit run pre-commit-setup --all-files ) 2>&1 | grep real
real 0m1,136s
...
and after:
...
$ ( time pre-commit run pre-commit-setup --all-files ) 2>&1 | grep real
real 0m0,635s
...
---
.pre-commit-config.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 351b9f6933f..a5b526b1eec 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -112,6 +112,7 @@ repos:
additional_dependencies: ["pyyaml"]
always_run: true
require_serial: true
+ pass_filenames: false
- id: check-file-mode
name: check-file-mode
language: unsupported_script
base-commit: 60466ce68ac1a2d93c7f39b2638e24f48125fbf9
--
2.51.0
reply other threads:[~2026-06-16 22:37 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260616223631.3456338-1-tdevries@suse.de \
--to=tdevries@suse.de \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox