Skip to content

Instantly share code, notes, and snippets.

@goffreder
Created November 22, 2009 11:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save goffreder/240546 to your computer and use it in GitHub Desktop.
Save goffreder/240546 to your computer and use it in GitHub Desktop.
CmdUtils.CreateCommand({
names: ["filestube-search"],
author: {name: "Emanuele Biancardi", email: "goffreder@gmail.com"},
license: "MPL,GPL",
description: "Searches for files on Filestube",
help: "Enter the file to search for",
arguments: [ {role: 'object', nountype: noun_arb_text, label: 'search file'}],
icon: "http://static.filestube.com/files/images/favicon.ico",
preview: function ft_search_preview(pblock,args) {
var msg = "Searching for <b>" + args.object.text + "</b> on Filestube...";
pblock.innerHTML = _(msg);
},
execute: function ft_search_execute(args) {
Utils.openUrlInBrowser("http://www.filestube.com/search.html?q=" + args.object.text + "&select=All");
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment