groovecoder/kuma — comment on commit e74a794669fb3a7c90cd5b1cf51186a8fd78928c
File: apps/dekicompat/management/commands/migrate_to_kuma_wiki.py line 655
By lmorchard:

JavaScript isn't the only language to be concerned with:

$ mysql -uroot wikidb

mysql> select count(*) from pages where page_text like '%function="syntax.JavaScript"%';
+----------+
| count(*) |
+----------+
| 712 |
+----------+
1 row in set (5.81 sec)

mysql> select count(*) from pages where page_text like '%function="syntax.%';
+----------+
| count(*) |
+----------+
| 1087 |
+----------+
1 row in set (5.74 sec)

I can't think of a SQL query off the top of my head to extract the specific list of languages involved, but it might be worth some data spelunking and analysis to figure out. (eg. parse pages with BeautifulSoup, look for `function="syntax.*"`, count the values of `function`)

I'd also suggest adding something like a `--withcode` option (eg. like `--nonen` and `--redirects`) and a SQL query in `gather_pages()` that looks like the second one above. That will exercise this feature by specifically migrating pages with syntax highlighting.