[Pkg-owncloud-commits] [owncloud] 227/258: Add support for keys in the info.xml
David Prévot
taffit at moszumanska.debian.org
Sat Oct 11 17:22:39 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository owncloud.
commit d6ee37856444c6b3d87533956290de3514f13dfe
Author: Lukas Reschke <lukas at owncloud.com>
Date: Thu Oct 9 15:00:36 2014 +0200
Add support for keys in the info.xml
This allows to have links to different doc base URLs
---
apps/files/appinfo/info.xml | 3 +++
apps/files_encryption/appinfo/info.xml | 5 ++++-
apps/files_external/appinfo/info.xml | 3 +++
apps/files_trashbin/appinfo/info.xml | 3 +++
apps/files_versions/appinfo/info.xml | 3 +++
apps/user_ldap/appinfo/info.xml | 1 +
lib/private/app.php | 10 +++++++++-
7 files changed, 26 insertions(+), 2 deletions(-)
diff --git a/apps/files/appinfo/info.xml b/apps/files/appinfo/info.xml
index 390d645..095927a 100644
--- a/apps/files/appinfo/info.xml
+++ b/apps/files/appinfo/info.xml
@@ -17,4 +17,7 @@
<webdav>appinfo/remote.php</webdav>
<filesync>appinfo/filesync.php</filesync>
</remote>
+ <documentation>
+ <user>user-files</user>
+ </documentation>
</info>
diff --git a/apps/files_encryption/appinfo/info.xml b/apps/files_encryption/appinfo/info.xml
index ec6498b..4be726e 100644
--- a/apps/files_encryption/appinfo/info.xml
+++ b/apps/files_encryption/appinfo/info.xml
@@ -11,7 +11,10 @@ Note that this app encrypts all files that are touched by ownCloud, so external
<author>Sam Tuke, Bjoern Schiessle, Florin Peter</author>
<requiremin>4</requiremin>
<shipped>true</shipped>
-
+ <documentation>
+ <user>user-encryption</user>
+ <admin>admin-encryption</admin>
+ </documentation>
<rememberlogin>false</rememberlogin>
<types>
<filesystem/>
diff --git a/apps/files_external/appinfo/info.xml b/apps/files_external/appinfo/info.xml
index 573d69c..c45ef57 100644
--- a/apps/files_external/appinfo/info.xml
+++ b/apps/files_external/appinfo/info.xml
@@ -11,6 +11,9 @@ In addition to the GUI, it is possible to configure external storage manually at
<author>Robin Appelman, Michael Gapczynski, Vincent Petry</author>
<requiremin>4.93</requiremin>
<shipped>true</shipped>
+ <documentation>
+ <admin>admin-external-storage</admin>
+ </documentation>
<types>
<filesystem/>
</types>
diff --git a/apps/files_trashbin/appinfo/info.xml b/apps/files_trashbin/appinfo/info.xml
index 7ecab85..6527efb 100644
--- a/apps/files_trashbin/appinfo/info.xml
+++ b/apps/files_trashbin/appinfo/info.xml
@@ -14,5 +14,8 @@
<types>
<filesystem/>
</types>
+ <documentation>
+ <user>user-trashbin</user>
+ </documentation>
<ocsid>166052</ocsid>
</info>
diff --git a/apps/files_versions/appinfo/info.xml b/apps/files_versions/appinfo/info.xml
index 2c4f38d..22d1ca3 100644
--- a/apps/files_versions/appinfo/info.xml
+++ b/apps/files_versions/appinfo/info.xml
@@ -14,6 +14,9 @@ In addition to the expiry of versions, ownCloud’s versions app makes certain n
<types>
<filesystem/>
</types>
+ <documentation>
+ <user>user-versions</user>
+ </documentation>
<default_enable/>
<ocsid>166053</ocsid>
</info>
diff --git a/apps/user_ldap/appinfo/info.xml b/apps/user_ldap/appinfo/info.xml
index 119860a..0ca65c1 100644
--- a/apps/user_ldap/appinfo/info.xml
+++ b/apps/user_ldap/appinfo/info.xml
@@ -14,6 +14,7 @@ A user logs into ownCloud with their LDAP or AD credentials, and is granted acce
<authentication/>
</types>
<documentation>
+ <admin>admin-ldap</admin>
</documentation>
<ocsid>166061</ocsid>
</info>
diff --git a/lib/private/app.php b/lib/private/app.php
index 754d27c..7006153 100644
--- a/lib/private/app.php
+++ b/lib/private/app.php
@@ -659,7 +659,15 @@ class OC_App {
$data[$child->getName()] = substr($xml, 13, -14); //script <description> tags
} elseif ($child->getName() == 'documentation') {
foreach ($child as $subChild) {
- $data["documentation"][$subChild->getName()] = (string)$subChild;
+ $url = (string) $subChild;
+
+ // If it is not an absolute URL we assume it is a key
+ // i.e. admin-ldap will get converted to go.php?to=admin-ldap
+ if(!\OC::$server->getHTTPHelper()->isHTTPURL($url)) {
+ $url = OC_Helper::linkToDocs($url);
+ }
+
+ $data["documentation"][$subChild->getName()] = $url;
}
} else {
$data[$child->getName()] = (string)$child;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git
More information about the Pkg-owncloud-commits
mailing list