DroidScript User Plugins

1,507 views
Skip to first unread message

Dave Smart

unread,
Jul 25, 2016, 11:12:27 AM7/25/16
to DroidScript
Hi Guys,

Do we have enough (unofficial) user plugins to start a user plugins list yet?

If you have a plugin that is good enough for public use (free or paid), then please let us know about it in this thread.  We would like to create a proper plugins list in this group at some point with links to the Github source or the Google Play store.  Eventually when we have enough it would be good to create a separate plugin registry web site where people can download, comment on and rate them too :)

Regards
David

Charles Wilt

unread,
Jul 25, 2016, 11:51:42 AM7/25/16
to DroidScript
I have two free plugins. One converts lat and long to UTM coordinates and the other converts XML to JSON.

Netpower8

unread,
Jul 25, 2016, 12:17:30 PM7/25/16
to DroidScript
I have several plugins.

Most significant is the creation of generic dialog boxes and an app screen with status bar on top and bottom this reduces development time very significantly.

Netpower8

unread,
Jul 25, 2016, 12:26:27 PM7/25/16
to DroidScript
Problem with my plugins. Currently some of them dont have documentation. Updating the code every few days...

JustAnotherDude

unread,
Jul 25, 2016, 5:45:28 PM7/25/16
to DroidScript
nice idea xD
note: (of topic) i'm planing to make a Apk/Spk share site (with google login and so) without a traffic limit if you know what i mean ;)

i use first a subdomain of my base domain ( daps.*** ) if this ok if i make a DroidScript app store (for free spk/apks)? :)

Alex F

unread,
Jul 26, 2016, 4:29:48 PM7/26/16
to DroidScript
Is there a site with plugin sample codes for ds? I want to try develop my own plugins and share them if they're useful :)
please send a link - thanks

Netpower8

unread,
Jul 26, 2016, 4:42:32 PM7/26/16
to DroidScript
There is. Droidscript wiki. Theres a sample plugin app framework there

Dave Smart

unread,
Jul 27, 2016, 4:08:36 AM7/27/16
to DroidScript
If you want to use eclipse to build plugins then you can download our official SDK here:- http://droidscript.org/plugin-sdk/

If you want to build plugins directly on your device, then you can install the free Java IDE called AIDE and then (in the premium version of DroidScript) generate simple (template) plugin code using the SDK menu in DroidScript.

If you don't have the premium version of DroidScript, you can still get the SDK's menu by creating a file in your DroidScript folder called _sdk_ and then the menu will appear next time you start DroidScript.

P.S. It would be great if someone with the necessary skills converted our plugin SDK to work for Android Studio too ;)

John LaDuke

unread,
Jul 27, 2016, 7:46:43 AM7/27/16
to DroidScript
My vote is that the plugins get put on github (or cloned if already there.) Included is an example of how to use the GitHub api to list the current plugins. All one of them.


tmp_26884-List Plugins On Github966754241.spk

JustAnotherDude

unread,
Jul 27, 2016, 6:12:53 PM7/27/16
to DroidScript
nice but why not all in-app view or in-app download? ^^

John LaDuke

unread,
Jul 27, 2016, 6:25:34 PM7/27/16
to DroidScript
Sounds like a good idea to me, just depends on my level of free time to write it! I've been checking out the github api on breaks and it certainly looks doable.

Syed Munawer Hassan

unread,
Jul 28, 2016, 12:08:57 AM7/28/16
to DroidScript
It will be better to provide a comprehensive tutorial for users so that more and more plugins can be developed by the users

JustAnotherDude

unread,
Aug 3, 2016, 2:41:06 PM8/3/16
to DroidScript
are now a online plugin site in progress ? (i need the information for my plugin manager ^^) and if yes: will it support in app downloads or in app view? (like a open API) :)

if no: can i try to make a selfmade site? :)

thx

Dave Smart

unread,
Aug 5, 2016, 8:54:34 AM8/5/16
to DroidScript
Just put up the source code for the FTPClient plugin (thanks go to Chris Ferrell for allowing us to post his code)

John: If you are a wiz with the github API.... I've always wanted to add a super simple github storage option to the DroidScript app icon long click menu.  So if you can find the time and fancy having a go for us, you can get the JavaScript source code for the DS UI from one of the recent alpha APKs ;)

John LaDuke

unread,
Aug 5, 2016, 6:46:14 PM8/5/16
to DroidScript
I've been looking at the api as well as a JavaScript SDK, so far I've learned its relatively easy to download an entire repository, but not as simple to download a single directory within that repo. Well, easier perhaps not trivial, to download repo FtpClient from user DroidScript-Plugins than directory FtpClient in Plugins repo of user DroidScript.

Still can't download, but an example of what I have so far can be found here: https://app.box.com/s/kar2hz4zeelyz2ofkjbkgr9zfxtwmdo6 (Tried to post SPK, but I think my phone is too tired right now. Wonder why? ;-))

Emma Nevada

unread,
Aug 9, 2016, 2:22:42 AM8/9/16
to DroidScript
So hows the progress on this though?

John LaDuke

unread,
Aug 9, 2016, 7:48:52 AM8/9/16
to DroidScript
A github repo client is semi-stalled, partly because of switching chunks of code from using a library to using the api because it feels "less klunky" for this application, but mostly hoping that Dave or Chris H reorganize the projects into top level repos.

Godwin Perri

unread,
Aug 10, 2016, 8:41:55 PM8/10/16
to DroidScript
Hi Guys, anybody know how i can start with the programme or video i can watch or tutorial to understand how to write the programme

John LaDuke

unread,
Aug 10, 2016, 9:45:53 PM8/10/16
to DroidScript

Dave Smart

unread,
Aug 11, 2016, 7:31:00 AM8/11/16
to DroidScript
OK, I'll look into creating a separate repo for each plugin as soon as I can.
Message has been deleted

Dave Smart

unread,
Aug 13, 2016, 8:37:23 AM8/13/16
to DroidScript
Separate repos now available for DS plugins :)

Dave Smart

unread,
Aug 13, 2016, 8:53:46 AM8/13/16
to DroidScript
Hi Guys,

If you think you have a plugin that is generally useful to the community and is documented at least to a basic level.  Then I'm happy to add it to our list and give you collaboration rights to the repository.  We can then use the Gihub starring system to rate each others plugins and watch the cream rise to the top ;)

If your plugin is a bit 'ropy' and has no docs, then you can still create a personal github account and share it with the community (and perhaps submit it to us when it's in better shape :)

Regards
David

Charles Wilt

unread,
Aug 13, 2016, 10:32:36 AM8/13/16
to DroidScript
How do we go about getting our plugins into the repo?

Alex F

unread,
Aug 13, 2016, 10:40:36 AM8/13/16
to DroidScript
Is the GraphView useful? :D
Case yes I can comment and expand it

Dave Smart

unread,
Aug 13, 2016, 12:54:30 PM8/13/16
to DroidScript
Hi Charles,

To get your plugins into our repo you need to do the following:-

- Get your self a GitHub user name (if you don't already have one) 
- Send us an email explaining what plugins you have to offer and what they do.
- Send us a copy of the plugins so I can check you have some basic docs. 
- Tell us the names of the repositories you want created.
- Tell us your Github user name and email address so we can add you as a collaborator.

Send that info to support[at]androidscript.org

Regards
David

Charles Wilt

unread,
Aug 13, 2016, 1:09:44 PM8/13/16
to DroidScript
Thanks David.

I will try to get one done this weekend.

Charles Wilt

unread,
Aug 13, 2016, 10:13:55 PM8/13/16
to DroidScript
Dave,

Does it matter if the plugin is javascript based?

John LaDuke

unread,
Aug 14, 2016, 11:09:07 PM8/14/16
to DroidScript
I've tried everything I could, but I can't seem to download a zipped repo from github via droidscript, only through an external browser. Anybody got any ideas? I'll post what I have so far...

"use strict";

var browser;
var user_api = "https://api.github.com/users/DroidScript";
var repos_api = "https://api.github.com/users/DroidScript/repos";

function OnStart() {
browser = new Browser();
app.AddLayout(browser.layout);
getUser();
getRepos();
}

function getUser() {
get(user_api)
.then(JSON.parse)
.then(
function(user) {
browser.setText(user);
});
}

function getRepos() {
var repoList = [];
get(repos_api)
.then(JSON.parse)
.then(
function(userRepos) {
userRepos.forEach(
function(repo) {
repoList.push(repo.name);
});
browser.setList(repoList);
});
}

function getDownload(title) {
app.OpenUrl("https://github.com/DroidScript/"+title+"/archive/master.zip");
}

function Browser() {
this.layout = app.CreateLayout("Linear", "FillXY");
var userText = createLabeledText(this.layout, "Repository:");
var fileList = app.CreateList("", 1.0, 0.8, "WhiteGrad");
fileList.SetTextColor1("#ff555558");
fileList.SetTextColor2("#ff555558");
fileList.SetTextMargins(0.04, 0, 0, 0);
fileList.SetOnTouch(getDownload);
this.layout.AddChild(fileList);

/* Set user and repository name. */
this.setText = function(user) {
userText.SetText(user.login);
};

/* Set branch or directory contents list. */
this.setList = function(array) {
fileList.SetList(array.join(","));
};
}


/**
* Create a pair of side by side text boxes,
* making the left text a label for the right
* text.
* @arg layout is which layout to add to.
* @arg label is what text to use for left text.
* @return right text.
*/
function createLabeledText(layout, label) {
var ltext = app.CreateText(label, 0.23, 0.08, "Left");
var rtext = app.CreateText("", 0.77, 0.08, "Left, Multiline");
var hlayout = app.CreateLayout("Linear", "Horizontal, FillX, Top");
rtext.SetTextSize(20);
hlayout.SetPadding(0.02, 0.01, 0.01, 0.01);
hlayout.SetBackColor("#225588");
hlayout.AddChild(ltext);
hlayout.AddChild(rtext);
layout.AddChild(hlayout);
return rtext;
}

/**
* Sends XMLHttpRequest GET request as new Promise.
* @arg {string} url - URL to receive request.
*/
function get(url) {
// Return a new promise.
// Great article on Promises at http://www.html5rocks.com/en/tutorials/es6/promises/
return new Promise(
function(resolve, reject) {
// Do the usual XHR stuff
var req = new XMLHttpRequest();
req.open('GET', url);
req.setRequestHeader("Accept", "application/vnd.github.v3+json");
req.onload = function() {
// This is called even on 404 etc
// so check the status
if (req.status == 200) {
// Resolve the promise with the response text
resolve(req.response);
}
else {
// Otherwise reject with the status text
// which will hopefully be a meaningful error
reject(Error(req.statusText));
}
};

// Handle network errors
req.onerror = function() {
reject(Error("Network Error"));
};

// Make the request
req.send();
});
}//end get

Dave Smart

unread,
Aug 15, 2016, 7:33:13 AM8/15/16
to DroidScript
Charles: It does not matter if your plugins are Java or JavaScript based

Dave Smart

unread,
Sep 18, 2016, 1:50:36 PM9/18/16
to androi...@googlegroups.com
Hi Guys, an Android Studio based DS sample plugin is now available here :-  


Message has been deleted

Dev Opex

unread,
Oct 13, 2016, 4:32:13 PM10/13/16
to DroidScript
If I make a paid plugin will I get the money or will you Dave
Reply all
Reply to author
Forward
Message has been deleted
0 new messages