Re: [PATCH v2 6/7] git-contributors: make revspec required and shebang fix

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 22, 2025 at 04:01:32PM +0100, Andrey Albershteyn wrote:
> Without default value script will show help instead of just hanging
> waiting for input on stdin.

Is it useful to be able to do

	git-contributors < fubar.patch

?

For the single usecase of generating announcement emails it probably
doesn't matter though.

--D

> Shebang fix for system with different python location than the
> /usr/bin one.
> 
> Signed-off-by: Andrey Albershteyn <aalbersh@xxxxxxxxxx>
> ---
>  tools/git-contributors.py | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/tools/git-contributors.py b/tools/git-contributors.py
> index 83bbe8ce0ee1dcbd591c6d3016d553fac2a7d286..628d6d0b4d8795e10b1317fa6fc91c6b98b21f3e 100755
> --- a/tools/git-contributors.py
> +++ b/tools/git-contributors.py
> @@ -1,4 +1,4 @@
> -#!/usr/bin/python3
> +#!/usr/bin/env python3
>  
>  # List all contributors to a series of git commits.
>  # Copyright(C) 2025 Oracle, All Rights Reserved.
> @@ -71,8 +71,7 @@ class find_developers(object):
>  
>  def main():
>      parser = argparse.ArgumentParser(description = "List email addresses of contributors to a series of git commits.")
> -    parser.add_argument("revspec", nargs = '?', default = None, \
> -            help = "git revisions to process.")
> +    parser.add_argument("revspec", help = "git revisions to process.")
>      parser.add_argument("--delimiter", type = str, default = '\n', \
>              help = "Separate each email address with this string.")
>      args = parser.parse_args()
> 
> -- 
> 2.47.0
> 
> 




[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux