2608 Commits

Author SHA1 Message Date
Elvish_Hunter
5f0b4178a7 wesnoth_addon_manager: warn and exit if a deactivated server is used 2023-03-10 00:08:54 +01:00
Elvish_Hunter
88fb94289c wesnoth_addon_manager: don't upload old-style add-ons
Fixes #7431.
2023-03-09 23:12:49 +01:00
Elvish_Hunter
841b42d26c wesnoth_addon_manager: update another deprecated method 2023-03-09 22:37:59 +01:00
Elvish_Hunter
1aac405869 wesnoth_addon_manager: update a deprecated method 2023-03-09 20:48:32 +01:00
Steve Cotton
f1ba89ec6d Fix mixed indents in the schema, and verify new additions
This uses tabs instead of spaces, because although that's not our coding
standard, it is only a few lines of changes.

The alternative of running wmlindent on these files changes 4700 lines.
2023-03-02 15:34:41 +01:00
Pentarctagon
c9eae7c35b 1.17.13+dev 2023-02-19 22:08:57 -06:00
Pentarctagon
113056c9e1 1.17.13 2023-02-19 22:08:56 -06:00
Elvish_Hunter
59b6049f9f wmlxgettext: always use Unix file paths in .pot files
Fixes #7380.
2023-02-16 23:28:05 +01:00
Tahsin Jahin Khalid
4d092347db unit_tree: comment out [advancefrom] 2023-02-12 10:11:45 -06:00
Tahsin Jahin Khalid
2cd0e5db03 unit_tree: add missing defines 2023-02-12 10:11:45 -06:00
Steve Cotton
49ebbb9709 Make fix_whitespace complain about mixing tabs and spaces
Ensures that files either use tabs for indentation or spaces for indentation,
but don't switch between the two within the same file.

This doesn't fix the whitespace, it's a simple check to flag it up
on the assumption that it's better to use an editor or code formatter
to clean up the file.

Elsewhere in the CI we use the luacheck tool - while that can detect
mixing tabs and spaces in a single line's indent, it doesn't check for
inconsistent indentation within a file.
2023-02-05 02:22:53 +01:00
Jason Stephenson
bce0493f03
Fix #7337: Byte Compiler Warnings for wesnoth-mode (#7338)
Switch from obsolete Emacs Lisp functions to modern functions in order
to remove two compiler warnings.

Properly quote lambdas with #' to remove two more compiler warnings.
2023-01-29 12:14:59 -05:00
Steve Cotton
1640076dc4 Make the CI check the indent on most of the unit tests
There were two `--exclude` statements both pointing at the data/test
directory before, which was a trivial bug.

Exclude cve_tests because of the binary file that's masquerading as a .cfg;
I think it's correct to exclude the whole directory because any new tests
added there might also use weird edge cases in the parsing.

Exclude lua_tests as a "keep this PR small" thing. We should fix the bugs in
wmlindent, but I don't want to take on that work.

The exclusion of TerrainWML is again because I don't want to take on the work
of working out whether it's problems with terrain masks or bugs in wmlindent.

Most of the files in those directories wouldn't be changed, the ones that would
(or would trigger an error about not being valid UTF-8 ) are:

* data/test/scenarios/cve_tests/test_cve_2018_1999023_2.cfg
* data/test/scenarios/lua_tests/functional/lua_functional.cfg
* data/test/scenarios/lua_tests/wesnoth/map/mapgen_filter.cfg
* data/test/scenarios/wml_tests/TerrainWML/test_terrain_mask.cfg
2023-01-20 02:28:54 +01:00
Pentarctagon
20c38a08e9 1.17.12+dev 2023-01-14 18:31:58 -06:00
Pentarctagon
b08582209b 1.17.12 2023-01-14 18:27:55 -06:00
Elvish_Hunter
d4c8d08064 wmllint: improve [campaign] rank= validation message 2022-12-30 23:33:59 +01:00
Elvish_Hunter
c1a074ea41 wmllint: validate values of [campaign] rank= 2022-12-30 22:49:36 +01:00
Toom
07dc953875
Escape < and > even if only one of them exists or if found multiple times (#7154)
* Escape < and > even if only one of them exists

In python negative index counts from the end, so without this change or another solution
"example with only < one side" would be converted to 
"example with only < one sid&gt;example with only < one side"

* Escape < and > even if found multiple times
2022-12-20 20:07:17 +01:00
Gunter Labes
2b47e63e8b
wmlunits: ignore a dependency on the addon itself 2022-12-19 16:16:35 +01:00
Pentarctagon
ec05dcd06d Wesnoth 1.17.11+dev. 2022-12-17 19:15:04 -06:00
Pentarctagon
ba8227e994 Wesnoth 1.17.11. 2022-12-17 19:14:04 -06:00
Pentarctagon
6c7dd0a25b 1.17.10+dev. 2022-11-19 23:38:26 -06:00
Pentarctagon
79b2385140 1.17.10. 2022-11-19 23:38:25 -06:00
Wedge009
26adbf4416 wmllint: As requested, adding recognition of WebP image labels.
Extension of #7079.
2022-11-03 11:26:30 +11:00
Wedge009
2010ffdbba
wmllint: Ignore labels for translation if a PNG extension is found (#7079)
* wmllint: Ignore labels for translation if a PNG extension is found.

Resolves #6995.
2022-11-03 11:16:37 +11:00
Dou1622
a667740fe5
Fix wmllint translation mark errors (#6966)
* Fix wmllint translation mark errors

* Added wesnoth-help domain

* Try to give better labels for the WC map generator settings which are now marked for translation.

Co-authored-by: Wedge009 <wedge009@wedge009.net>
2022-11-01 13:40:49 +11:00
Pentarctagon
5700e96a59 1.17.9+dev. 2022-10-15 21:09:26 -05:00
Pentarctagon
6682ef8ab8 1.17.9. 2022-10-15 21:09:25 -05:00
Tahsin Jahin Khalid
fde3c8df29 wmllint: add terrain code updaters
Allows updating maps by wmllint. Accommodates #7042
2022-10-10 21:47:42 +08:00
Pentarctagon
490434bc3c 1.17.8+dev 2022-09-18 23:20:45 -05:00
Pentarctagon
3b2cf63779 1.17.8 2022-09-18 23:19:48 -05:00
Steve Cotton
a2747cc651 wmllint: stop adding wesnoth-icon.png to messages
We're had at least two people look at the "good first issue" list, pick up
the wmllint warnings, open a PR, and then get a response that these .pngs
shouldn't be added by default. That's not a welcoming introduction.

IIRC we didn't get full consensus that these should never be added, but I
think it's time to open a "just drop that code, no options" PR. If someone
wants it back in a subset of circumstances, they can always create a PR to
readd it along with adding an option to enable it.
2022-08-31 21:27:15 +02:00
Pentarctagon
5549900c96 1.17.7+dev 2022-08-20 19:55:18 -05:00
Pentarctagon
8a4ff22985 1.17.7 2022-08-20 19:55:18 -05:00
Tommy
2d37a13bb8 WML: Add macros for screen_fade, and modify FLASH to use it as well
New macros:
 * SCREEN_FADE_OUT - to replace FADE_TO_BLACK in most cases
 * SCREEN_FADE_IN - to replace FADE_IN in most cases
 * SCREEN_FADE r g b duration
   - convenience wrapper for [screen_fade] with 255 alpha
 * SCREEN_UNFADE duration
   - convenience wrapper for [screen_fade] with 0 alpha
 * FLASH r g b actionWML
   - like FLASH_WHITE etc but takes a colour
 * FLASH_LIGHTNING actionWML
   - flashes an appropriate colour and plays lightning.ogg

Modified macros:
 * FLASH_WHITE/RED/GREEN/BLUE}
   - these now use [screen_fade] not [color_adjust]
2022-08-07 23:11:21 +12:00
Pentarctagon
78764ccd58
1.17.6+dev 2022-07-19 19:31:18 -05:00
Pentarctagon
ab8fe65b83
1.17.6 2022-07-19 19:30:24 -05:00
mattsc
ce9ba142bc Add new AI aspect allow_ally_villages 2022-06-22 08:00:50 -07:00
Elvish_Hunter
f1fb3a73a8 wmlunits: used os.path.join() to build paths instead of string concatenation 2022-06-21 18:29:57 +02:00
Elvish_Hunter
b1c6029917 wmlunits: used shutil.move() instead of calling mv as a subprocess
This also means moving files in a more pythonic way and removing two functions (bash and shell) which aren't used anywhere else.
2022-06-20 23:24:47 +02:00
Pentarctagon
5857964d61
1.17.5+dev. 2022-06-19 09:07:13 -05:00
Pentarctagon
f6cfad7b50
1.17.5. 2022-06-19 09:07:13 -05:00
Elvish_Hunter
d16557bae1 wmlscope: used an enumerator instead of strings in scan_for_definitions() state checks 2022-06-18 19:06:07 +02:00
Elvish_Hunter
cfbad6b81c wmlscope: avoid crashing on non-UTF8 files 2022-06-18 19:06:07 +02:00
Celtic Minstrel
473c6e468e
Fix wmlindent quote detection (#6764)
* wmlindent: Fix parsing quotes in comments

* Remove unnecessary wmlindent ignores

* Run wmlindent
2022-06-18 09:37:55 +02:00
Elvish_Hunter
8b8f99e65a wmllint: fixed translation marks not being removed from values when checking if a string is empty 2022-05-28 22:03:25 +02:00
Elvish_Hunter
f7859ad104 wmllint: automatically remove {SOUND:SLOW} and {SOUND:POISON} lines
Part of point 5 of issue #6403
2022-05-17 23:57:08 +02:00
Pentarctagon
9753b9538d
1.17.4+dev 2022-05-15 09:43:37 -05:00
Pentarctagon
712a7c96be
1.17.4 2022-05-15 09:42:25 -05:00
Tahsin Jahin Khalid
4c42228c52
wmllint: add Giant Stoat -> Frost Stoat monster ID change (#6694) 2022-05-14 23:24:03 +02:00