Commit graph

18 commits

Author SHA1 Message Date
Ignacio R. Morelle
780cced9c2 terrain2wiki: wesnoth-old.git -> wesnoth.git 2014-03-02 19:17:30 -03:00
Thibault Févry
df427826fa Fix typos in terrain2wiki.py 2013-08-24 19:16:14 +02:00
Thibault Févry
34bcf22807 Fix typos 2013-07-13 21:10:20 +02:00
thibault
0ed4441b09 Update terrain2wiki.py to work with github transition better. Also fixing docstrings. 2013-07-03 20:21:52 +02:00
Alexander van Gessel (AI0867)
2561c5b28c Use sourceforge rather than GNA for terrain image URLs 2013-03-27 12:50:15 +01:00
Eric S. Raymond
7f85fa000c The git transition.
Most references to and dependencies on Subversion have been removed.
"+svn" is now "+dev". Files that can't be fixed yet have a FIXME-GIT
comment in them; most of these are in the website tests.
2013-03-26 10:44:47 -04:00
Ignacio R. Morelle
d65124a8c2 terrain2wiki: Remove leading/trailing whitespace in lines before parsing
The Dark Flagstones terrain had .aliasof at the last line before the
closing tag, which caused a newline to be output right before </code> in
the wiki page, and in turn causing MW to generate invalid XHTML.

This change makes the generated wiki page valid XHTML again (except for
another problem with the actual glamdrol theme, not the page contents).
2012-05-12 21:29:00 +00:00
Ignacio R. Morelle
15510a8dcd terrain2wiki: Wrap .string and .aliasof column contents in <code>...
...and use &#124; instead of the Unicode broken bar (fixes bug #19678)

This also extends the vertical bar escaping to the .aliasof column
contents (in case we ever get base terrains with vertical bars)

By using <code> we should be able to stick to byte-accurate contents
without compromising readability, by styling terrain type strings in a
default monospace font suitable for code display (i.e. | and l should be
distinguishable from each other).
2012-05-12 21:11:07 +00:00
Mark de Wever
7efcde580f Escape the pipe-symbol in the wiki uploader.
Fixes the display off terrains with a pipe-symbol in the wiki.

Fixes bug #19678.
2012-04-30 20:29:52 +00:00
Thibault Févry
e718249a40 Fix the picture for some special cases. 2011-10-23 20:23:05 +00:00
Thibault Févry
85c307f8a2 Made terrain2wiki.py also show a picture of the terrain, looks better now. 2011-10-23 20:11:32 +00:00
Thibault Févry
3bce1693c2 Fixed an issue where terrain2wiki.py...
...would not remove # wmllint: ignore from output
2011-10-23 19:49:27 +00:00
Thibault Févry
1b8718c457 2011-06-27T06:33:30Z!shadowm@wesnoth.org and 2011-06-27T06:57:47Z!shadowm@wesnoth.org...
...changed terrain2wiki.py output. Fixing terrain2wiki.py to work with
the terrain.cfg changes..
2011-10-23 19:42:21 +00:00
Thibault Févry
9a13492bcc Make terrain2wiki.py compatible with python3...
...(Doesn't break python2 obviously). This might be usefull for Linux
distribs that come with python3 by default.
2011-03-21 22:32:18 +00:00
Mark de Wever
231c8929b1 Some minor tweaks to terrain2wiki.py.
The output of this version is used to generate the current version of
the wiki page [1].

[1] http://wiki.wesnoth.org/TerrainCodeTableWML
2011-03-13 18:59:32 +00:00
Steven Panek
9a6855f78c Set svn:executable and svn:eol-style. 2011-03-06 06:29:07 +00:00
Thibault Févry
3d95e9f7fa Use a default value similar to the one used in wiki_grabber.py.
Also a small doc update.
2011-03-05 23:54:45 +00:00
Thibault Févry
a7c96bb4d6 Added a new script: data/tools/terrain2wiki.py
Same as data/tools/terrain2wiki.rb except it works with current format
It also works with arguments, so you can choose source and destination
files

Still need some changes but it already works. Only feature that was in
ruby tool and not in this one is stats from. It will be added in a
future version.

mvt_alias and def_alias will also be added in a future version in the
alias column.

Another thing to not is that the tool does not parse terrains with an
'hidden=yes' because these shouldn't appear in a terrain reference.

Pep8 and Pylint results are good.
2011-03-05 23:37:07 +00:00