{"version":"1.0","type":"rich","title":"A git hook that checks whether there is an issue number in the first line of your commit message","description":"This example demonstrates a Git hook that enforces commit message conventions by checking the first line for an issue number. It shows a Python script using the `sys` module to read the commit message file path passed as an argument. The script opens the file in read-write mode, reads all lines, and examines the first line for a `#` character, which indicates an issue reference. If no issue number is found, the script prints an error message and exits with a non-zero status code, blocking the commit. The code relies on standard Python file I/O and the `sys.argv` list to access command-line arguments, without external visualization libraries.","provider_name":"VizHub AI Studio","provider_url":"https://next.vizhub.com","html":"<iframe src=\"https://next.vizhub.com/viz/gist-22aadce3015cb15c3eafc667cdf4ae79?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"1\"></iframe>","width":960,"height":500,"cache_age":3600}