Right now it just catches arcanist noisy tags, and include a script to
automatically clean these.
Follow up on http://lists.llvm.org/pipermail/llvm-dev/2019-December/137848.html
Differential D80978
Add a git hook script that can be manually setup to run some checks on every push mehdi_amini on Jun 1 2020, 10:41 PM. Authored by
Details Right now it just catches arcanist noisy tags, and include a script to Follow up on http://lists.llvm.org/pipermail/llvm-dev/2019-December/137848.html
Diff Detail
Unit Tests Event Timeline
Comment Actions Thanks for the patch. git pre-hook seems to be a clever trick. I need to play with this.
Comment Actions This is nice! I'm pretty tired of seeing Arcanist boilerplate in commits. Let's do this!
Comment Actions Style-wise I cannot find more issues now. Honestly I tried this script just now. Without git pull --rebase origin master, my local master branch was stale. This script said: % git push origin HEAD:master `git rev-list 4171f80d5416eccbeebe8864410d576d7dc61eaa..bb67f1a4400a19318713375655999f733418a33b` returned 128 fatal: Invalid revision range 4171f80d5416eccbeebe8864410d576d7dc61eaa..bb67f1a4400a19318713375655999f733418a33b The diagnostic can probably be made more helpful. After git pull --rebase origin master: % git push origin HEAD:master Pushing to "refs/heads/master" on remote "git@github.com:llvm/llvm-project.git" - 8ffb2097cc1 [ELF] Refine LMA offset propagation rule in D76995 Enumerating objects: 22, done. Counting objects: 100% (22/22), done. Delta compression using up to 72 threads Compressing objects: 100% (11/11), done. Writing objects: 100% (12/12), 2.04 KiB | 2.04 MiB/s, done. Total 12 (delta 9), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (9/9), completed with 9 local objects. To github.com:llvm/llvm-project.git 4171f80d541..8ffb2097cc1 HEAD -> master The first two lines are added by this script. They look good to me. Comment Actions Thanks for catching this! I think the script should just ignore this case and let git fails. I added the check.
|
This version handles both Summay: ... (on the same line) and Summary:\nmulti lines
In addition, I added --date=now to reset author date to committer date.