<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Helvetica;
        panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
        {font-family:"Lucida Console";
        panose-1:2 11 6 9 4 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
h3
        {mso-style-priority:9;
        mso-style-link:"T\00EDtulo 3 Car";
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:13.5pt;
        font-family:"Times New Roman",serif;
        font-weight:bold;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
code
        {mso-style-priority:99;
        font-family:"Courier New";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML con formato previo Car";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
span.EstiloCorreo17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.Ttulo3Car
        {mso-style-name:"T\00EDtulo 3 Car";
        mso-style-priority:9;
        mso-style-link:"T\00EDtulo 3";
        font-family:"Times New Roman",serif;
        mso-fareast-language:CA;
        font-weight:bold;}
span.HTMLconformatoprevioCar
        {mso-style-name:"HTML con formato previo Car";
        mso-style-priority:99;
        mso-style-link:"HTML con formato previo";
        font-family:"Courier New";
        mso-fareast-language:CA;}
span.w
        {mso-style-name:w;}
span.pre
        {mso-style-name:pre;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="CA" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US">Hi,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I am trying to make my code good for all Actions in the project.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Yesterday I was trying to format my code using clang. I looked at that:<o:p></o:p></span></p>
<h3 style="mso-margin-top-alt:9.6pt;margin-right:0cm;margin-bottom:18.0pt;margin-left:0cm;background:#FCFCFC">
<span style="font-size:15.0pt;font-family:"Helvetica",sans-serif;color:#404040">Commit hooks<o:p></o:p></span></h3>
<p style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:18.0pt;margin-left:0cm;line-height:18.0pt;background:#FCFCFC;box-sizing: border-box;font-variant-ligatures: normal;font-variant-caps: normal;orphans: 2;text-align:start;widows: 2;-webkit-text-stroke-width: 0px;text-decoration-thickness: initial;text-decoration-style: initial;text-decoration-color: initial;word-spacing:0px">
<span style="font-family:"Arial",sans-serif;color:#404040">GDAL provides pre-commit hooks to run code linters before a commit is made. The hooks are cloned with the repository and can be installed using <a href="https://pre-commit.com/"><span style="color:#2980B9">pre-commit</span></a>:<o:p></o:p></span></p>
<pre style="background:white;box-sizing: border-box;background:linear-gradient(-90deg, rgba(0, 0, 0, 0.01) 1px, transparent 1px) 0% 0% / 12px 12px, linear-gradient(rgba(0, 0, 0, 0.01) 1px, transparent 1px) 0% 0% / 12px 12px, linear-gradient(-90deg, rgba(0, 0, 0, 0.01) 1px, transparent 1px) 0% 0% / 12px 12px, linear-gradient(rgba(0, 0, 0, 0.01) 1px, transparent 1px) 0% 0% / 12px 12px, linear-gradient(transparent 3px, transparent 3px, transparent 78px, transparent 78px) 0% 0% / 12px 12px, linear-gradient(-90deg, transparent 1px, transparent 1px) 0% 0% / 12px 12px, linear-gradient(-90deg, transparent 3px, transparent 3px, transparent 78px, transparent 78px) 0% 0% / 12px 12px, linear-gradient(transparent 1px, transparent 1px) 0% 0% / 12px 12px, rgb(248, 248, 248);overflow:auto"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">python3</span><span class="w"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#BBBBBB"> </span></span><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">-m</span><span class="w"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#BBBBBB"> </span></span><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">pip</span><span class="w"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#BBBBBB"> </span></span><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">install</span><span class="w"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#BBBBBB"> </span></span><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">pre-commit<o:p></o:p></span></pre>
<pre style="background:white"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">pre-commit</span><span class="w"><span style="font-size:9.0pt;font-family:"Lucida Console";color:#BBBBBB"> </span></span><span style="font-size:9.0pt;font-family:"Lucida Console";color:#333333">install<o:p></o:p></span></pre>
<p style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:18.0pt;margin-left:0cm;line-height:18.0pt;background:#FCFCFC;box-sizing: border-box;font-variant-ligatures: normal;font-variant-caps: normal;orphans: 2;text-align:start;widows: 2;-webkit-text-stroke-width: 0px;text-decoration-thickness: initial;text-decoration-style: initial;text-decoration-color: initial;word-spacing:0px">
<span style="font-family:"Arial",sans-serif;color:#404040">Once installed, the hooks can be run manually via </span><span class="pre"><span style="font-size:11.0pt;font-family:Consolas;color:black;border:solid #E1E4E5 1.0pt;padding:2.0pt;background:white">pre-commit</span></span><code><span style="font-size:11.0pt;font-family:Consolas;color:black;border:solid #E1E4E5 1.0pt;padding:2.0pt;background:white"> </span></code><span class="pre"><span style="font-size:11.0pt;font-family:Consolas;color:black;border:solid #E1E4E5 1.0pt;padding:2.0pt;background:white">run</span></span><code><span style="font-size:11.0pt;font-family:Consolas;color:black;border:solid #E1E4E5 1.0pt;padding:2.0pt;background:white"> </span></code><span class="pre"><span style="font-size:11.0pt;font-family:Consolas;color:black;border:solid #E1E4E5 1.0pt;padding:2.0pt;background:white">--all-files</span></span><span style="font-family:"Arial",sans-serif;color:#404040">.<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span lang="EN-US">Since Then, I think, the linting test in Code Checks (</span><span lang="ES"><a href="https://github.com/AbelPau/gdal/actions/runs/7886238742/job/21519074148"><span lang="EN-US">Pharentesis · AbelPau/gdal@91bbaa9 (github.com)</span></a></span><span lang="EN-US">)
 always fails but I have no Idea why.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Can anyone tell me why it’s failing?? Did I do something wrong with the pre-commit?
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Thanks a lot in advance!<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:CA"> </span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" width="0" style="width:375.0pt">
<tbody>
<tr>
<td width="310" style="width:232.5pt;padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:11.5pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA">Abel Pau Garcia</span></b><span style="font-size:12.0pt;mso-fareast-language:CA">
</span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:9.0pt;font-family:"Arial",sans-serif;color:#669900;mso-fareast-language:CA">GIS developer</span></b><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
<td width="190" valign="top" style="width:142.5pt;padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal" align="right" style="text-align:right"><span style="font-size:12.0pt;mso-fareast-language:CA"><img border="0" width="134" height="50" style="width:1.3958in;height:.5208in" id="Imagen_x0020_8" src="cid:image001.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/creaf-signature.png"></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA"><a href="mailto:a.pau@creaf.uab.cat"><b><span style="color:blue">a.pau@creaf.uab.cat</span></b></a></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA"><a href="https://teams.microsoft.com/l/chat/0/0?users=a.pau@creaf.uab.cat"><b><span style="color:blue">Let's chat on Teams!</span></b></a></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA">Tel. +34 934814277</span></b><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
<td width="190" valign="top" style="width:106.5pt;padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal" align="right" style="text-align:right"><span style="font-size:12.0pt;mso-fareast-language:CA"><img border="0" width="105" height="50" style="width:1.0937in;height:.5208in" id="Imagen_x0020_7" src="cid:image002.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/so-en-signature.png"></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><span lang="ES"><a href="https://twitter.com/CREAF_ecologia" target="_blank"><span lang="CA" style="font-size:12.0pt;color:#0563C1;mso-fareast-language:CA;text-decoration:none"><img border="0" width="17" height="17" style="width:.177in;height:.177in" id="Imagen_x0020_6" src="cid:image003.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/twitter-icon-signature.png"></span></a><a href="https://www.linkedin.com/company/1363052?trk=tyah&trkInfo=clickedVertical:company,clickedEntityId:1363052,idx:2-1-2,tarId:1465807877789,tas:creaf" target="_blank"><span lang="CA" style="font-size:12.0pt;color:#0563C1;mso-fareast-language:CA;text-decoration:none"><img border="0" width="17" height="17" style="width:.177in;height:.177in" id="Imagen_x0020_5" src="cid:image004.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/linkedin-icon-signature.png"></span></a><a href="https://www.youtube.com/c/creafecologia" target="_blank"><span lang="CA" style="font-size:12.0pt;color:#0563C1;mso-fareast-language:CA;text-decoration:none"><img border="0" width="17" height="17" style="width:.177in;height:.177in" id="Imagen_x0020_4" src="cid:image005.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/youtube-icon-signature.png"></span></a><a href="https://www.instagram.com/CREAF_ecologia/" target="_blank"><span lang="CA" style="font-size:12.0pt;color:#0563C1;mso-fareast-language:CA;text-decoration:none"><img border="0" width="17" height="17" style="width:.177in;height:.177in" id="Imagen_x0020_3" src="cid:image006.png@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/instagram-icon-signature.png"></span></a></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA"><a href="http://www.creaf.cat" target="_blank"><b><span style="color:#003300">www.creaf.cat</span></b></a><b> |
</b><a href="http://blog.creaf.cat" target="_blank"><b><span style="color:#003300">http://blog.creaf.cat</span></b></a></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
<td valign="top" style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal" align="right" style="text-align:right"><span style="font-size:12.0pt;mso-fareast-language:CA"><img border="0" width="105" height="50" style="width:1.0937in;height:.5208in" id="Imagen_x0020_2" src="cid:image007.jpg@01DA5E80.0F154D10" alt="https://www.creaf.cat/sites/default/files/uab_logo_signatura.png"></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td colspan="2" style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#003300;mso-fareast-language:CA">CREAF. Campus UAB. Edifici C. 08193 Bellaterra (Barcelona)</span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td colspan="2" style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:8.5pt;font-family:"Arial",sans-serif;color:#999999;mso-fareast-language:CA"><br>
Before printing this electronic message, think about the environment.</span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td colspan="2" style="padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:12.0pt;mso-fareast-language:CA"><img border="0" width="500" height="6" style="width:5.2083in;height:.0625in" id="Imagen_x0020_1" src="cid:image008.jpg@01DA5E80.0F154D10" alt="http://www.creaf.uab.cat/_signatura/line.gif"></span><span style="mso-fareast-language:CA"><o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span style="mso-fareast-language:CA"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="ES"><o:p> </o:p></span></p>
</div>
</body>
</html>