eclipse-kura / kura

Eclipse Kura™ is a versatile framework to supercharge your edge devices, streamlining the process of configuring your gateway, connecting sensors, and IoT devices to seamlessly collect, process, and send data to the cloud.
https://eclipse.dev/kura/
Eclipse Public License 2.0
499 stars 306 forks source link

[Web] Enable app installation through drag & drop from Eclipse Marketplace #138

Closed dwoodard1 closed 8 years ago

kartben commented 8 years ago

An MPC URL (the one that's in the "INSTALL" button that one drags&drop into Eclipse IDE (or Kura!!!) looks something like: http://marketplace.eclipse.org/marketplace-client-intro?mpc_install=150453

When catching this URL in the drop event, what is important here is the ID of the solution: here 150453. Next step is to make an HTTP GET call to http://marketplace.eclipse.org/node/150453/api/p

The result looks like the following, ie. all the metadata needed. Looks like updateurl+ui ID will just be the path to the .dp, and voila!

<?xml version="1.0" encoding="UTF-8"?>
<marketplace>
    <node id="150453" name="Lua Development Tools" url="http://marketplace.eclipse.org/content/lua-development-tools">
        <type>resource</type>
        <categories>
            <category id="1966" name="Programming Languages" url="http://marketplace.eclipse.org/category/categories/programming-languages"/>

        </categories>
        <tags>
            <tag id="841" name="Lua" url="http://marketplace.eclipse.org/category/free-tagging/lua"/>
            <tag id="2326" name="ldt" url="http://marketplace.eclipse.org/category/free-tagging/ldt"/>
            <tag id="51" name="IDE" url="http://marketplace.eclipse.org/category/free-tagging/ide"/>
            <tag id="573" name="tools" url="http://marketplace.eclipse.org/category/free-tagging/tools"/>
            <tag id="146" name="editor" url="http://marketplace.eclipse.org/category/free-tagging/editor"/>

        </tags>
        <owner>Simon Bernard</owner>
        <favorited>16</favorited>
        <installstotal>17412</installstotal>
        <installsrecent>0</installsrecent>
        <shortdescription>
            <![CDATA[<p>Lua Development Tools (LDT) is about providing Lua developers with an IDE providing the user experience developers expect from any other tool dedicated to a static programming language.</p><p>Like many other dynamic languages, Lua is so flexible that it is hard to analyze enough to provide relevant and powerful tooling.<br />
LDT is using Metalua, to analyze Lua source code and provide nice user assistance.</p><p>LDT is an Open Source tool, licensed under the EPL.</p><p>Visit <a href="http://marketplace.eclipse.org/content/lua-development-tools/click">Lua Development Tools web page</a> for more information, and make sure you are encouraging the development team by favoriting LDT on the Marketplace!</p>
]]>
        </shortdescription>
        <body>
            <![CDATA[<p>Lua Development Tools (LDT) is about providing Lua developers with an IDE providing the user experience developers expect from any other tool dedicated to a static programming language.</p><p>Like many other dynamic languages, Lua is so flexible that it is hard to analyze enough to provide relevant and powerful tooling.<br />
LDT is using Metalua, to analyze Lua source code and provide nice user assistance.</p><p>LDT is an Open Source tool, licensed under the EPL.</p><p>Visit <a href="http://marketplace.eclipse.org/content/lua-development-tools/click">Lua Development Tools web page</a> for more information, and make sure you are encouraging the development team by favoriting LDT on the Marketplace!</p>
]]>
        </body>
        <created>1320940561</created>
        <changed>1456168281</changed>
        <foundationmember>1</foundationmember>
        <homepageurl>http://www.eclipse.org/ldt</homepageurl>
        <image>
            <![CDATA[http://marketplace.eclipse.org/sites/default/files/styles/ds_medium/public/LDT_128.png?itok=Xx6AWKjQ]]>
        </image>
        <screenshot>
            <![CDATA[http://marketplace.eclipse.org/sites/default/files/styles/medium/public/screenCodeCompletion.png?itok=eNHdfkG0]]>
        </screenshot>
        <license>EPL</license>
        <companyname>
            <![CDATA[Eclipse.org]]>
        </companyname>
        <status>Production/Stable</status>
        <supporturl>
            <![CDATA[https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced;product=LDT;classification=Tools]]>
        </supporturl>
        <version>1.2.0</version>
        <eclipseversion>4.5, 4.4, 4.3, 4.2, 4.1, 4.6</eclipseversion>
        <min_java_version>java_6</min_java_version>
        <updateurl>http://download.eclipse.org/koneki/releases/stable/</updateurl>
        <ius>
            <iu selected="TRUE">org.eclipse.koneki.ldt.feature.group</iu>

        </ius>
        <platforms>
            <platform>Windows</platform>
            <platform>Mac</platform>
            <platform>Linux/GTK</platform>

        </platforms>

    </node>
</marketplace>
dwoodard1 commented 8 years ago

This issue is addressed with pull request #240 .

--Dave