-
-
Save phmongeau/70487 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* This is a template command */ | |
CmdUtils.CreateCommand({ | |
name: "timer", | |
icon: "http://www.lemieuxster.com/favicon.ico", | |
homepage: "e.ggtimer.com", | |
author: { name: "Philippe Mongeau", email: "ph.mongeau@gmail.com"}, | |
license: "GPL", | |
description: "set a timer using e.ggtimer.com", | |
help: "type the name of the command followed by the time you want to set", | |
takes: {"time": noun_arb_text}, | |
preview: function( pblock, time ) { | |
pblock.innerHTML = "set timer to " + time.text | |
}, | |
execute: function( time ) { | |
displayMessage("the timer will ring in " + time.text); | |
Utils.openUrlInBrowser("http://e.ggtimer.com/" + time.text); | |
} | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment