Permalink
Browse files

New way of numbering API versions.

  • Loading branch information...
Jenyay committed Jan 15, 2018
1 parent 517a792 commit ddfba44243728c8cbc54d90a0bee2ca88c4ae7af
Showing with 129 additions and 790 deletions.
  1. +1 −40 buildtools/contentgenerators.py
  2. +4 −28 fabfile.py
  3. +1 −9 plugins/autorenamer/autorenamer/plugin.xml
  4. +1 −9 plugins/changepageuid/changepageuid/plugin.xml
  5. +1 −9 plugins/counter/counter/plugin.xml
  6. +1 −9 plugins/datagraph/datagraph/plugin.xml
  7. +1 −8 plugins/debugevents/debugevents/plugin.xml
  8. +1 −8 plugins/diagrammer/diagrammer/plugin.xml
  9. +1 −8 plugins/examples/eventsplugin/plugin.xml
  10. +2 −8 plugins/examples/firstplugin_01/plugin.xml
  11. +1 −8 plugins/examples/firstplugin_02/plugin.xml
  12. +1 −9 plugins/export2html/export2html/plugin.xml
  13. +1 −9 plugins/externaltools/externaltools/plugin.xml
  14. +1 −9 plugins/hackpage/hackpage/plugin.xml
  15. +1 −9 plugins/htmlformatter/htmlformatter/plugin.xml
  16. +1 −9 plugins/htmlheads/htmlheads/plugin.xml
  17. +1 −9 plugins/lightbox/lightbox/plugin.xml
  18. +1 −9 plugins/livejournal/livejournal/plugin.xml
  19. +1 −9 plugins/markdown/markdown/plugin.xml
  20. +1 −9 plugins/organizer/organizer/plugin.xml
  21. +1 −9 plugins/pagetypecolor/pagetypecolor/plugin.xml
  22. +1 −9 plugins/readingmode/readingmode/plugin.xml
  23. +1 −9 plugins/sessions/sessions/plugin.xml
  24. +1 −9 plugins/snippets/snippets/plugin.xml
  25. +1 −9 plugins/source/source/plugin.xml
  26. +1 −9 plugins/spoiler/spoiler/plugin.xml
  27. +1 −9 plugins/statistics/statistics/plugin.xml
  28. +1 −9 plugins/style/style/plugin.xml
  29. +1 −9 plugins/tableofcontents/tableofcontents/plugin.xml
  30. +1 −9 plugins/template/template/plugin.xml
  31. +1 −9 plugins/testdebug/testdebug/plugin.xml
  32. +1 −9 plugins/texequation/texequation/plugin.xml
  33. +1 −9 plugins/thumbgallery/thumbgallery/plugin.xml
  34. +1 −9 plugins/updatenotifier/updatenotifier/plugin.xml
  35. +1 −9 plugins/webpage/webpage/plugin.xml
  36. +1 −1 src/outwiker/core/__init__.py
  37. +4 −7 src/outwiker/core/appinfo.py
  38. +5 −21 src/outwiker/core/packageversion.py
  39. +7 −21 src/outwiker/core/pluginsloader.py
  40. +6 −20 src/outwiker/core/xmlversionparser.py
  41. +1 −59 src/test/test_packageversion.py
  42. +1 −1 src/test/test_pluginsloader.py
  43. +47 −85 src/test/test_xmlversionparser.py
  44. +1 −2 src/tests_core.py
  45. +1 −8 test/plugins/testempty1/testempty1/plugin.xml
  46. +1 −8 test/plugins/testempty2/testempty2/plugin.xml
  47. +1 −8 test/plugins/testempty3/testempty3/plugin.xml
  48. +1 −8 test/plugins/testempty4/testempty4/plugin.xml
  49. +1 −8 test/plugins/testfromfuture/testfromfuture/plugin.xml
  50. +1 −8 test/plugins/testinvalid1/testinvalid1/plugin.xml
  51. +1 −8 test/plugins/testinvalid2/testinvalid2/plugin.xml
  52. +1 −8 test/plugins/testinvalid4/testinvalid4/plugin.xml
  53. +1 −8 test/plugins/testinvalid5/testinvalid5/plugin.xml
  54. +1 −8 test/plugins/testinvalid6/plugin.xml
  55. +1 −8 test/plugins/testinvalid7/testinvalid7/plugin.xml
  56. +1 −8 test/plugins/testoutdated/testoutdated/plugin.xml
  57. +1 −8 test/plugins/testpage/testpage/plugin.xml
  58. +1 −8 test/plugins/testwikicommand/testwikicommand/plugin.xml
  59. +3 −101 test_build_sitecontent.py
@@ -1,4 +1,4 @@
# -*- coding: UTF-8 -*-
# -*- coding: utf-8 -*-
from io import StringIO
@@ -95,42 +95,3 @@ def _appendChanges(self, buf, verinfo):
if verinfo.changes:
buf.write(u'\n')
class SitePluginsTableGenerator (object):
def __init__(self, appInfoList):
self._appInfoList = appInfoList[:]
self._appInfoList.sort(key=lambda x: x.appname)
def make(self):
buf = StringIO()
for appinfo in self._appInfoList:
assert appinfo.requirements is not None
self._appendAppInfo(buf, appinfo)
return buf.getvalue().strip()
def _appendAppInfo(self, buf, appinfo):
# Append plugin name and link
name_text = u'||[[{name} -> {link}]] '.format(name=appinfo.appname,
link=appinfo.appwebsite)
buf.write(name_text)
# Append description
description_text = u'||{} '.format(appinfo.description)
buf.write(description_text)
# OS
os_list = appinfo.requirements.os[:]
os_list.sort(reverse=True)
os_list_text = u', '.join(os_list)
os_text = u'|| {} '.format(os_list_text)
buf.write(os_text)
# OutWiker version
version_text = u'|| {}.{}.{} ||'.format(
appinfo.requirements.outwiker_version[0],
appinfo.requirements.outwiker_version[1],
appinfo.requirements.outwiker_version[2],
)
buf.write(version_text)
buf.write(u'\n')
View
@@ -7,7 +7,9 @@
import os.path
import glob
import sys
import urllib.request, urllib.error, urllib.parse
import urllib.request
import urllib.error
import urllib.parse
import shutil
from fabric.api import local, lcd, settings, task, cd, put, hosts
@@ -49,8 +51,7 @@
downloadAppInfo,
getLocalAppInfoList,
)
from buildtools.contentgenerators import (SiteChangelogGenerator,
SitePluginsTableGenerator)
from buildtools.contentgenerators import SiteChangelogGenerator
from buildtools.builders import (BuilderWindows,
BuilderSources,
BuilderPlugins,
@@ -396,31 +397,6 @@ def _print_changelog(path_to_xml, lang):
print(changelog)
@task
def plugins_list(lang=None):
'''
Print plugins list for th site
'''
if lang is None:
print_error(u'Error. No language specified')
sys.exit(1)
appinfo_list = []
for plugin_name in PLUGINS_LIST:
path_to_xml = os.path.join(PLUGINS_DIR,
plugin_name,
plugin_name,
PLUGIN_VERSIONS_FILENAME)
xml_content = readTextFile(path_to_xml)
parser = XmlVersionParser([lang])
appinfo = parser.parse(xml_content)
appinfo_list.append(appinfo)
generator = SitePluginsTableGenerator(appinfo_list)
text = generator.make()
print(text)
@task
def site_versions():
'''
@@ -3,16 +3,8 @@
<name>AutoRenamer</name>
<updates>http://jenyay.net/uploads/Outwiker/AutoRenamer/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.0</actions>
<gui>2.0</gui>
<pages>1.0, 2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>ChangePageUID</name>
<updates>http://jenyay.net/uploads/Outwiker/ChangePageUid/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>Counter</name>
<updates>http://jenyay.net/uploads/Outwiker/Counter/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>DataGraph</name>
<updates>http://jenyay.net/uploads/Outwiker/DataGraph/plugin.xml</updates>
<requirements>
<outwiker>1.8.0.750 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.0</actions>
<gui>2.0</gui>
<pages>1.0, 2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -4,14 +4,7 @@
<updates>http://jenyay.net/uploads/Outwiker/DebugEvents/plugin.xml</updates>
<requirements>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -4,14 +4,7 @@
<updates>http://jenyay.net/uploads/Outwiker/Diagrammer/plugin.xml</updates>
<requirements>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -4,14 +4,7 @@
<updates>http://example.com/pluginname/plugin.xml</updates>
<requirements>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -2,13 +2,7 @@
<info>
<name>FirstPlugin</name>
<requirements>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<os>Windows, Linux</os>
<api>2.835</api>
</requirements>
</info>
@@ -4,14 +4,7 @@
<updates>http://example.com/pluginname/plugin.xml</updates>
<requirements>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>Export2Html</name>
<updates>http://jenyay.net/uploads/Outwiker/Export2HtmlPlugin/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>ExternalTools</name>
<updates>http://jenyay.net/uploads/Outwiker/ExternalTools/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>HackPage</name>
<updates>http://jenyay.net/uploads/Outwiker/HackPage/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>HtmlFormatter</name>
<updates>http://jenyay.net/uploads/Outwiker/HtmlFormatter/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>HtmlHeads</name>
<updates>http://jenyay.net/uploads/Outwiker/HtmlHeads/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>Lightbox</name>
<updates>http://jenyay.net/uploads/Outwiker/Lightbox/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>Livejournal</name>
<updates>http://jenyay.net/uploads/Outwiker/LivejournalPlugin/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
@@ -3,16 +3,8 @@
<name>Markdown</name>
<updates>http://jenyay.net/uploads/Outwiker/Markdown/plugin.xml</updates>
<requirements>
<outwiker>2.1.0.833 dev</outwiker>
<os>Windows, Linux</os>
<packages>
<core>2.0</core>
<actions>1.1</actions>
<gui>2.0</gui>
<pages>2.0</pages>
<utilites>1.0</utilites>
<libs>1.0</libs>
</packages>
<api>2.835</api>
</requirements>
<data lang="en">
Oops, something went wrong.

0 comments on commit ddfba44

Please sign in to comment.