[mapserver-dev] Typo fixing script in docs

Jeff McKenna jmckenna at gatewaygeomatics.com
Tue Feb 2 09:48:53 PST 2016


On 2016-02-02 1:35 PM, Jeff McKenna wrote:
> On 2016-02-02 12:32 PM, Even Rouault wrote:
>> Hi,
>>
>> I've added in a branch ( https://github.com/mapserver/docs/pull/143 ) an
>> interactive script ./scripts/fix_typos.sh that helps identifying
>> common typo
>> fixes, and the fixes it helped finding. This uses the codespell Python
>> script (
>> upstream is https://github.com/lucasdemarchi/codespell . Actual
>> version is my
>> forked version with a few improvements ) that comes with its own
>> dictionary.
>> I've also added the Debian Lintian dictionary and the QGIS dictionary.
>> The
>> dictionaries are more code oriented than general purpose I guess, but
>> there is
>> a good amount of computerese in our docs, so it is still valuable.
>>
>> It requires Python 3 (and the first time it is run, git to download
>> codespell
>> and curl to download the additional dictionaries)
>>
>> You can use with : ./scripts/fix_typos.sh
>> and answering the question when a typo is identified.
>>
>> A white list of words can be edited in ./scripts/fix_typos.sh itself,
>> and when
>> a word is OK only in a specific context, you can add the full line to
>> whitelist
>> in scripts/typos_whitelist.txt (sensitive to starting and trailing
>> whitespace/tabulations, and only work on LF terminated files, hence a
>> conversion of 2 files from CRLF to LF).
>>
>> Note: it is only run on en/ files, the dictionaries being only for
>> English.
>>
>> Opinions ?
>>
>> Even
>>
>
>
> Sounds great. When you get to documenting the steps (likely in
> /development/documentation.txt) be sure to include steps for Windows
> users as well, as many doc contributors are on Windows.  Also, it would
> be great to include steps for Python2 users, as I know the MS4W
> environment was recently upgraded to Python 2.7.11 support. (yes I ask a
> lot, but, you asked for my opinion :)
>
> Thanks!
>
> -jeff
>
>
>

Maybe the answers to both of my questions/requests is to set this up on 
a shared server, and then document the steps to login and run.

-jeff



-- 
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/


More information about the mapserver-dev mailing list