Ignacio R. Morelle
96be3ead4c
wmllint: Exclude preprocessor directives from [part] children check
...
This solves spurious errors when attempting to use #ifdef within [part].
2013-05-22 21:44:14 -04:00
Elvish_Hunter
8200214e9b
wmllint, wmlscope and wmlindent: fixed bug caused by Windows' command prompt appending double quotes to arguments
2013-02-23 13:04:12 +00:00
Ignacio R. Morelle
a3694f9b84
Revert "wmllint: ids in [time_area] are not associated to units...
...
...most of the time"
Done already in 2012-08-19T22:42:19Z!anonymissimus@arcor.de by anonymissimus.
This reverts commit 2013-02-19T06:44:24Z!shadowm@wesnoth.org.
2013-02-19 06:51:28 +00:00
Ignacio R. Morelle
05b12ecb69
wmllint: ids in [time_area] are not associated to units most of the time
...
The exception is when the [time_area] action is part of an event and
it contains an id-based SUF inside an SLF, but that should be rare
enough.
2013-02-19 06:44:24 +00:00
Ignacio R. Morelle
5f0ce8d010
Make wmllint recognize victory_string, defeat_string,
...
...gold_carryover_string, and notes_string (all from the [objectives]
tag) as attributes that need to be made translatable
2013-01-17 05:43:48 +00:00
Anonymissimus
e18b1f75d0
fix wmllint rule for removal of [effect]unit_type/gender=
2012-11-12 22:29:34 +00:00
Anonymissimus
fb69ed0523
fix wmllint complaining about unknown [time_area]id=
2012-08-19 22:42:19 +00:00
Anonymissimus
890b6d0b3b
possibly half-baked fix for wmllint complaining...
...
...about unknown [event]id=something
2012-08-19 22:42:11 +00:00
Anonymissimus
b7ccb8091b
fix # wmllint: deathcheck off directive being ignored in some cases
2012-08-19 22:42:02 +00:00
Alexander van Gessel
a1e5070ab6
Don't strip underscores from keys when trying to remove a translation mark
2012-08-19 21:13:03 +01:00
Alexander van Gessel
c9a5c32bb4
Rename [object]duration=level to [object]duration=scenario
2012-05-01 22:13:52 +01:00
Anonymissimus
3bbe460a4e
wmmlint rule for previous commit
...
No updates to mainline wml required.
2012-03-29 15:28:34 +00:00
Anonymissimus
a396df7abe
cheap wmllint rule for viewing_side -> side
...
Global renaming; there is only 1 false positive in my addons
and none in mainline. I hope nobody uses this string as a tag
or variable name.
2012-03-27 19:50:39 +00:00
Anonymissimus
5d0284a513
wmllint rule for the 2 deprecations in my latest revisions
...
No changes to mainline needed. These were only valid for
almost one year however.
2012-02-14 21:25:33 +00:00
Anonymissimus
5e311eb9b5
remove wmllint rule for empty side=...
...
...in remove/place_shroud,modify_side/ai,gold
The first three have "all sides" as default if no side info given,
the ladder two have inline SSF support and "all sides" as default
as well, so it's valid syntax which shouldn't be warned about.
2012-02-14 21:25:08 +00:00
Anonymissimus
6419bb4841
remove the rule making wmllint putting side=...
...
...into set*,allow*,disallow_recruit,store_gold
Since it is valid syntax now (again, but defaulting to all sides).
2012-02-14 21:23:06 +00:00
Anonymissimus
820b021f9c
Fix some of the id checking logic in wmllint.
...
If we have [message]id=, narrator, unit and second_unit are wrong values.
They need speaker= as keys.
2012-01-22 22:36:16 +00:00
Anonymissimus
b271273d33
Revert revisions of mine: 2012-01-19T17:58:30Z!anonymissimus@arcor.de, 2012-01-19T17:59:02Z!anonymissimus@arcor.de
...
Since it introduced wrong line numbers in wmllint messages.
And probably messes up files in case dryrun isn't used.
Reintroduces the wmllint breakage problem with Hornshark Island.
2012-01-20 22:19:01 +00:00
Anonymissimus
8bdf59969f
Make wmllint id checks respect comma-separated lists of ids.
...
Another bug which I found due to the previous fix. I had added that
feature in the engine's SUF some time after the check in wmllint did
already no longer work.
2012-01-20 21:37:38 +00:00
Anonymissimus
6b45146d62
Fix leading whitespace being ignored when searching for subtag start.
...
Reenables the check for "unknown xy referred to by id".
Fix for a bug report in the forum:
http://forums.wesnoth.org/viewtopic.php?p=519028#p519028
(It's not clear to me what the purpose of the subtag_depth variable is
though.)
2012-01-20 21:37:21 +00:00
Anonymissimus
5d1c3d227b
Make wmllint ignore embedded lua. There's no bug report for this.
...
Apparently it didn't already, it just didn't break so far, but the lua
I added in Hornshark let it choke.
wmllint ignores lines with << until a line with >> now (start and
end lines included).
esr: have a look pls
2012-01-19 17:58:30 +00:00
Eric S. Raymond
65ab58a574
Fix wmllint glitches.
2011-11-15 04:58:47 +00:00
Thibault Févry
c408f32b5f
Strip trailing whitespaces.
...
Some other changes to make code look more pythonish. No important changes.
2011-10-22 00:17:25 +00:00
Ignacio R. Morelle
f0a3854f1b
wmllint: Handle deprecated implicit side=1 in more actions;...
...
...run the new code in mainline
Shame on you, esr.
This commit handles [remove/place_shroud], [gold] and [modify_side/ai]...
...using modified code derived from patch #2666
2011-08-02 00:38:36 +00:00
Ignacio R. Morelle
97da3fcaa3
Teach wmllint to fix deprecated implicit side=1 in [store_gold] actions
...
This uses esr's rule from 2011-07-03T10:55:21Z!esr@thyrsus.com rather than patch #2666 's.
2011-08-02 00:38:06 +00:00
Eric S. Raymond
f880c89e81
Teach wmllint to detect missing side attribute in recruit,
...
...allow_recruit and disallow_recruit. Fix all mainline instances of
this glitch.
2011-07-03 10:55:21 +00:00
Eric S. Raymond
b9f997685f
Apply unit-list tests to extra_recruit.
2011-05-17 16:27:00 +00:00
Eric S. Raymond
389de25030
Address bug #18016 : Please add next_scenario checks to wmllint.
2011-05-11 16:16:57 +00:00
Eric S. Raymond
33195adc1f
Try to wildcaede range_* and type_* checks for translation marks.
2011-05-09 08:33:40 +00:00
Eric S. Raymond
2d6af3c664
Remove an asymmetry.
...
SPECIAL_EXTRA_HEAL exists now.
2011-05-09 07:46:11 +00:00
Eric S. Raymond
d33bd35d96
Address FR at bug #18047 : type_*= and range_*=
...
aren't recognized as keys that should have translation marks.
2011-05-09 07:24:45 +00:00
Steven Panek
e5b93a6887
'naptha' -> 'naphtha'.
2011-05-08 22:50:42 +00:00
Eric S. Raymond
c4adb689e7
wmllint, spelling, and punctuation cleanup.
2011-05-08 15:13:41 +00:00
Steven Panek
464b1a5764
Made wmllint ignore UTF-8 minus signs when spellchecking.
2011-04-19 00:08:54 +00:00
Thibault Févry
6674487fb0
Remove W604 pep8 warning on files. Use repr(x) instead of deprecated
2011-03-25 20:46:50 +00:00
Ignacio R. Morelle
e0b0a18104
WML preprocessor: implement #ifver, #ifnver MACRO <op> <version>
...
Currently, the specified MACRO is not expanded further, so if it
contains code inclusions with {} those will not be resolved.
Furthermore, MACRO should not take arguments. The whole idea is that it
should be defined to simple text such as "1.7.5" like Wesnoth does for
WESNOTH_VERSION since 2011-03-22T06:40:15Z!shadowm@wesnoth.org.
2011-03-23 03:20:39 +00:00
Eric S. Raymond
2afb4a71f4
Clean up things so all macros are argument-typechecked again.
2011-03-15 02:45:11 +00:00
Thibault Févry
2288ef0939
Removed a lot of trailing whitespaces. Shouldn't be anymore in python scripts.
2011-03-12 02:22:21 +00:00
Eric S. Raymond
a9ed162e55
Address bug #17752 :
...
wmllint wants to apply special notes for commented abilities.
2011-02-20 14:21:14 +00:00
Alexander van Gessel
3abd28ef34
Allow spaces in notepairs
2011-02-20 02:51:41 +01:00
Alexander van Gessel
f051dbedfd
Don't complain that a [unit] misses a side key...
...
...if it's located in a [side] tag
2011-02-19 19:13:11 +01:00
Alexander van Gessel
5b9b9f243c
Don't make wmllint check if the usage type matches a standard one.
...
Non-standard ones work just fine
2011-02-19 15:48:40 +01:00
Alexander van Gessel
9d008ac25b
Add a skip-side directive to wmllint to make it not complain...
...
...about breaking up the [side] list into multiple files
2011-02-19 05:49:32 +01:00
Alexander van Gessel
878f5d38bf
Widen the usability of wmllint: ignore a bit
2011-02-19 05:30:21 +01:00
Alexander van Gessel
19d9757ea9
Fix a wmllint crash
2011-02-19 01:12:38 +01:00
Alexander van Gessel
c8e1f39da3
Make ignore/noconvert work for pangoization
2011-02-19 01:12:34 +01:00
Alexander van Gessel
b7b3d320bf
Make the ignore and noconvert directives work for adding underscores...
...
...as well as removing them
2011-02-19 00:41:29 +01:00
Alexander van Gessel
1958a0c2ba
Make wmllint accept all [*_frame] variants, not just a specific subset
2011-02-10 18:11:55 +01:00
Eric S. Raymond
3b0190d7ae
With this change, all sanity checks run clean.
2011-01-16 22:54:04 +00:00
Eric S. Raymond
a1fdc572ce
wmllint cleanup.
2011-01-16 22:37:27 +00:00