From 68cf434afb7fb2bba6be05c15f500d654e345788 Mon Sep 17 00:00:00 2001 From: Jesse Hallam Date: Wed, 25 Jul 2018 14:22:42 -0400 Subject: [PATCH] bundle the plugin with the plugin_id in the tar This fits our existing practice of distributing plugins, and enables easier manual installation of same. --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 3551830..cadd654 100644 --- a/Makefile +++ b/Makefile @@ -69,7 +69,7 @@ ifneq ($(HAS_WEBAPP),) mkdir -p dist/$(PLUGIN_ID)/webapp/dist; cp -r webapp/dist/* dist/$(PLUGIN_ID)/webapp/dist/; endif - cd dist/$(PLUGIN_ID) && tar -zcvf ../$(PLUGIN_ID).tar.gz * + cd dist && tar -cvzf $(PLUGIN_ID).tar.gz $(PLUGIN_ID) @echo plugin built at: dist/$(PLUGIN_ID).tar.gz @@ -95,8 +95,8 @@ ifneq ($(and $(MM_SERVICESETTINGS_SITEURL),$(MM_ADMIN_USERNAME),$(MM_ADMIN_PASSW http --print b POST $(MM_SERVICESETTINGS_SITEURL)/api/v4/plugins/$(PLUGIN_ID)/enable else ifneq ($(wildcard ../mattermost-server/.*),) @echo "Installing plugin via filesystem. Server restart and manual plugin enabling required" - mkdir -p ../mattermost-server/plugins/$(PLUGIN_ID) - tar -C ../mattermost-server/plugins/$(PLUGIN_ID) -zxvf dist/$(PLUGIN_ID).tar.gz + mkdir -p ../mattermost-server/plugins + tar -C ../mattermost-server/plugins -zxvf dist/$(PLUGIN_ID).tar.gz else @echo "No supported deployment method available. Install plugin manually." endif