[libcamera-devel] [PATCH v1 1/4] utils: checkstyle: Add __repr__ method to CommitFile class
Kieran Bingham
kieran.bingham at ideasonboard.com
Wed Jul 5 02:00:59 CEST 2023
Quoting Laurent Pinchart via libcamera-devel (2023-06-12 23:47:48)
> Add a custom representation to the CommitFile class in order to
> facilitate debugging.
>
Reviewed-by: Kieran Bingham <kieran.bingham at ideasonboard.com>
> Signed-off-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> ---
> utils/checkstyle.py | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/utils/checkstyle.py b/utils/checkstyle.py
> index 5cc523b6fba3..7da888d8c365 100755
> --- a/utils/checkstyle.py
> +++ b/utils/checkstyle.py
> @@ -191,6 +191,9 @@ class CommitFile:
> else:
> self.__filename = info[1]
>
> + def __repr__(self):
> + return f'{self.__status} {self.__filename}'
> +
> @property
> def filename(self):
> return self.__filename
> --
> Regards,
>
> Laurent Pinchart
>
More information about the libcamera-devel
mailing list