Merge lp:~mhall119/developer-ubuntu-com/apidoc-fixes into lp:developer-ubuntu-com

Proposed by Michael Hall on 2016-07-19
Status: Merged
Approved by: Daniel Holbach on 2016-07-20
Approved revision: 228
Merged at revision: 226
Proposed branch: lp:~mhall119/developer-ubuntu-com/apidoc-fixes
Merge into: lp:developer-ubuntu-com
Diff against target: 31 lines (+7/-3)
2 files modified
api_docs/importers/__init__.py (+1/-1)
update_apidocs.sh (+6/-2)
To merge this branch: bzr merge lp:~mhall119/developer-ubuntu-com/apidoc-fixes
Reviewer Review Type Date Requested Status
Daniel Holbach (community) 2016-07-19 Approve on 2016-07-20
Review via email: mp+300490@code.launchpad.net

Description of the Change

Fixes a couple of API doc importation bugs

1) When doing the link re-writing the importer would look for any matching Element, now it will look for any matching Element only in the same Version

2) Replaced the original OnlineAccounts library and docs with qml-module-ubuntu-onlineaccounts2-doc

3) Add Ubuntu.OnlineAccounts.Client API docs

To post a comment you must log in.
228. By Michael Hall on 2016-07-19

Add Ubuntu.OnlineAccounts.Client API docs

Daniel Holbach (dholbach) wrote :

LGTM.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'api_docs/importers/__init__.py'
2--- api_docs/importers/__init__.py 2015-12-10 14:36:35 +0000
3+++ api_docs/importers/__init__.py 2016-07-19 15:51:22 +0000
4@@ -93,7 +93,7 @@
5 url_base = match.group('url').split('/')[-1]
6 if self.verbosity >= 2:
7 print "URL base: %s" % url_base
8- element = Element.objects.filter(source_file=url_base, source_format=self.SOURCE_FORMAT)
9+ element = Element.objects.filter(source_file=url_base, source_format=self.SOURCE_FORMAT, section__topic_version=self.version)
10 if element:
11 element = element[0]
12 new_link = '/'.join(('/api', element.section.topic_version.language.topic.slug, element.section.topic_version.language.slug, element.section.topic_version.slug, element.fullname, ''))
13
14=== modified file 'update_apidocs.sh'
15--- update_apidocs.sh 2016-02-24 17:41:56 +0000
16+++ update_apidocs.sh 2016-07-19 15:51:22 +0000
17@@ -37,8 +37,12 @@
18 python manage.py import_qdoc -Pp -t apps -l qml -r development -s "Graphical Interface" -n Ubuntu.Components -i /tmp/apidoc_sources/usr/share/ubuntu-ui-toolkit/doc/html/ubuntuuserinterfacetoolkit.index
19
20 ## Ubuntu.OnlineAccounts
21-./get_package.py accounts-qml-module-doc
22-python manage.py import_qdoc -Pp -t apps -l qml -r development -s "Platform Services" -N Ubuntu.OnlineAccounts -i /tmp/apidoc_sources/usr/share/accounts-qml-module/doc/html/onlineaccounts-qml-api.index
23+./get_package.py qml-module-ubuntu-onlineaccounts2-doc
24+gunzip -f /tmp/apidoc_sources/usr/share/doc/ubuntu-onlineaccounts2/html/ubuntuonlineaccounts2.index.gz
25+python manage.py import_qdoc -Pp -t apps -l qml -r development -s "Platform Services" -N Ubuntu.OnlineAccounts -i /tmp/apidoc_sources/usr/share/doc/ubuntu-onlineaccounts2/html/ubuntuonlineaccounts2.index
26+
27+./get_package qml-module-ubuntu-onlineaccounts-client-doc
28+python manage.py import_qdoc -Pp -t apps -l qml -r development -s "Platform Services" -N Ubuntu.OnlineAccounts.Client -i /tmp/apidoc_sources/usr/share/online-accounts-client/doc/html/onlineaccountsclient-qml-api.index
29
30 ## Ubuntu.Content
31 ./get_package.py libcontent-hub-doc

Subscribers

People subscribed via source and target branches