[QGIS-Developer] Pre-commit error: astyle not found

DelazJ delazj at gmail.com
Thu Jul 13 03:53:41 PDT 2017


Hmmm... While looking for a solution I realized that the few qgis astyle
mentions I found on the web were related to build process... But I just
want to check my changes and not try to build anything on Windows (I gave
up a while ago).

And yes, (unfortunately?) Qgis documentation/guidelines is mostly oriented
Unix like and indeed the prepare-commit command fail on the Windows
Commands Prompt. But I actually use a git bash application I've installed
at the time I was trying to build QGIS on my Windows (something related to
mingw) and it supports those bash commands.

Anyway, I "worked around" by commenting the astyle check part in the
prepare-commit.sh file, recreate the pre-commit file and I can commit
without error. I know this disables the check but it wasn't necessary for
the changes I did (i actually wanted to set the same configuration for the
repo than on my xenial).

But if anything I can do to have this work without resorting to build
process....

Le jeudi 13 juillet 2017, Matthias Kuhn <matthias at opengis.ch> a écrit :
> On 07/13/2017 12:27 PM, DelazJ wrote:
>> Hi Nyall,
>>
>> Sorry for that maybe noob question but you mean setting in the
>> Cmakelists file at the root of the repo:
>> SET (WITH_ASTYLE TRUE CACHE BOOL "If you want to contribute you should
>> reindent with scripts/prepare-commit.sh (using 'our' style)").
>> Am I right? Doing that doesn't change anything; still get the "astyle.sh
>> not found" error message. Anything else I should do?
>
> Yes, that's the option.
>
> You need to build again after enabling it, but after looking at your
> error message, this mentions a shell script (.sh) which I don't think is
> compatible with Windows.
>
> Matthias
> _______________________________________________
> QGIS-Developer mailing list
> QGIS-Developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20170713/48e099ce/attachment-0001.html>


More information about the QGIS-Developer mailing list