raphsabb (owner)

Revisions

gist: 47455 Download_button fork
public
Public Clone URL: git://gist.github.com/47455.git
Embed All Files: show embed
lh #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/*
This is my first contribution to the ubiquity project. I always find myself performing google searches for lifehacker articles that I've read, or, that I'm looking for. With this command, my search is a keyboard-only 3 step process. Thank you ubiquity!
 
*/
 
makeSearchCommand({
  name: "lh",
  author: { name: "Raphael Sabbat", homepage: "http://raphsabb.blogspot.com"},
  help:
'eg. <i>"lh ubiquity"</i>' + '<br />' +
'eg. <i>"lh ubuntu"</i>' + '<br />' +
'eg. <i>"lh hive five"</i>',
 
  url: "http://www.lifehacker.com/search/{QUERY}",
  icon: "http://www.lifehacker.com/favicon.ico",
  description: "Search <a href=\"http://www.lifehacker.com\">Lifehacker.com</a> for the given words.",
  
  preview: function(pBlock, directObj) {
    if (directObj.text)
      pBlock.innerHtml = "Searches Lifehacker.com for " + directObj.text;
    else
      pBlock.innerHTML = "Searches Lifehacker.com for the given words.";
  }
});