From 7809a9fdd8c908e216844e906d58671c69a9e20e Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Tue, 5 Nov 2019 12:31:04 -0500 Subject: [PATCH] Bug 23975: Add ability to search and install plugins from GitHub It would be nice to be able to search and install plugins directly from GitHub ( and GitLab if possible ). This would make it easier to verify the authenticity of plugins and make discovering new plugins easier as well as making installation of plugins simpler. Test Plan: 1) Apply this patch 2) Add the new block for plugin_repos to your koha-conf.xml 3) Restart all the things! 4) Browse to the plugins home page 5) Try searching for 'patrons' in the new search box 6) Verify you get results! Signed-off-by: Martin Renvoize Signed-off-by: David Nind Signed-off-by: Kyle M Hall Signed-off-by: Tomas Cohen Arazi Signed-off-by: Martin Renvoize --- debian/templates/koha-conf-site.xml.in | 12 +++++++ etc/koha-conf.xml | 12 +++++++ .../prog/en/modules/plugins/plugins-home.tt | 36 +++++++++++++++++++ plugins/plugins-home.pl | 23 ++++++++++++ 4 files changed, 83 insertions(+) diff --git a/debian/templates/koha-conf-site.xml.in b/debian/templates/koha-conf-site.xml.in index c8a7bee487..dc9d10053d 100644 --- a/debian/templates/koha-conf-site.xml.in +++ b/debian/templates/koha-conf-site.xml.in @@ -408,6 +408,18 @@ __END_SRU_PUBLICSERVER__ developers use it to catch bugs related to strict SQL modes --> 0 0 + + + ByWater Solutions + bywatersolutions + github + + + Theke Solutions + thekesolutions + github + + diff --git a/etc/koha-conf.xml b/etc/koha-conf.xml index 17e3e1be4e..9f0d6a1b11 100644 --- a/etc/koha-conf.xml +++ b/etc/koha-conf.xml @@ -232,6 +232,18 @@ __PAZPAR2_TOGGLE_XML_POST__ developers use it to catch bugs related to strict SQL modes --> 0 0 + + + ByWater Solutions + bywatersolutions + github + + + Theke Solutions + thekesolutions + github + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt index 5d598c525e..3ae2cd5e3a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt @@ -27,6 +27,7 @@ [% IF ( CAN_user_plugins_manage ) %]
Upload plugin +
+ +
+
+
+
+ +
+
+
+
+
[% END %]

Plugins

+ [% IF search_results %] +

Search results

+ + + + + + + + + + + [% FOREACH sr IN search_results %] + + + + + + + [% END %] +
NameDescriptionOrganization 
[% sr.result.name %][% sr.result.description %][% sr.repo.name %]
+ [% END %] + [% UNLESS ( plugins ) %] [% UNLESS ( method ) %]
No plugins installed
@@ -161,6 +196,7 @@ [% INCLUDE 'calendar.inc' %]