Skip to content

Instantly share code, notes, and snippets.

View phmongeau's full-sized avatar
🤖

Philippe Mongeau phmongeau

🤖
View GitHub Profile
@phmongeau
phmongeau / wavepot
Created October 12, 2014 18:05
music thingy
function pulse(freq, offset, t) {
return Math.sin(2 * Math.PI * t * freq)
+ Math.sin(2 * Math.PI * t * (freq + (1* offset)))
+ Math.sin(2 * Math.PI * t * (freq + (2*offset)));
}
function noise() {
return Math.random();
}
@phmongeau
phmongeau / x
Created February 25, 2009 22:00
//Note: This command was automatically generated by the create-new-search-command command.
CmdUtils.makeSearchCommand({
name: "twitfinder",
url: "http://twitter.com/search/users?q={QUERY}",
icon: "http://twitter.com/favicon.ico",
description: "Searches twitter.com"
});
@phmongeau
phmongeau / x
Created February 25, 2009 22:01
//Note: This command was automatically generated by the create-bookmarklet-command command.
CmdUtils.makeBookmarkletCommand({
name: "hey,-birdhive!",
url: "javascript:BHQL();function%20BHQL(){var%20p=window.prompt('Enter%20the%20URL%20you%20want%20to%20share%20with%20Birdhive');if(p){var%20url='http://twitter.com/home?status='+escape('@birdhive%20'+p.substring(0,129));if(p.substring(0,1)=='%20'){var%20w=window.open(url);w.focus();}else{var%20dm=window.confirm('Would%20you%20like%20to%20send%20this%20as%20a%20DM%20(hit%20no/cancel%20to%20send%20via%20@birdhive)?');if(dm){url='http://twitter.com/home?status='+escape('DM%20birdhive%20'+p);};window.location.href=url;};};};""javascript:BHQL();function%20BHQL(){var%20p=window.prompt('Enter%20the%20URL%20you%20want%20to%20share%20with%20Birdhive');if(p){var%20url='http://twitter.com/home?status='+escape('@birdhive%20'+p.substring(0,129));if(p.substring(0,1)=='%20'){var%20w=window.open(url);w.focus();}else{var%20dm=window.confirm('Would%20you%20like%20to%20send%2
@phmongeau
phmongeau / x
Created February 25, 2009 22:44
/* 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},
@phmongeau
phmongeau / x
Created February 28, 2009 20:04
//Note: This command was automatically generated by the create-new-search-command command.
CmdUtils.makeSearchCommand({
name: "hashtag",
url: "http://hashtags.org/search?query={QUERY}",
icon: "http://hashtags.org/favicon.ico",
description: "Searches hashtags.org"
});
//Note: This command was automatically generated by the create-new-search-command command.
//Note: This command was automatically generated by the create-bookmarklet-command command.
CmdUtils.makeBookmarkletCommand({
name: "moourl",
url: "javascript:void(location.href='http://moourl.com/create/?source='+escape(location.href));"
});
//fonction to transform link
function processNode() {
var href = jQuery(this).attr("href");
if(/[a-z]\:\/\//.exec(href) === null) {
if(href[0] == "/")
jQuery(this).attr("href", "http://thepiratebay.org" + href);
}
}
var id = 100358;
var width = 220;
jetpack.statusBar.append({
html: (<><![CDATA[
<style type="text/css">
#so-statusbar {
font-family: Tahoma;
font-size: 11px;
height: 22px;
// generated by create bookmarklet command
CmdUtils.makeBookmarkletCommand({
name: "bit.ly sidebar",
url: "javascript:var%20e=document.createElement('script');e.setAttribute('language','javascript');e.setAttribute('src','http://bit.ly/bookmarklet/load.js');document.body.appendChild(e);void(0);",
});
// generated by create search command
CmdUtils.makeSearchCommand({
name: "caffeine",
url: "http://www2.sandbox.google.com/search?hl=en&safe=off&q={QUERY}&aq=f&oq=&aqi=",
});