Skip to content

Instantly share code, notes, and snippets.

View thepauljones's full-sized avatar

Paul Jones thepauljones

View GitHub Profile
@thepauljones
thepauljones / uuids.js
Last active July 5, 2017 19:23
Retrieve some current AVOD and SVOD uuids for testing
module['exports'] = function listUUIDs(hook) {
getUUIDS('avod', avodData => {
getUUIDS('svod', svodData => {
postToSlack(avodData, svodData);
});
});
/**
* @param type String can be 'avod' or 'svod'
**/
@thepauljones
thepauljones / timtamlottery.js
Created March 4, 2016 09:22
Open sourced code to determine who in the team gets the overige tim tams after everyone has had one
var totalTimTamsinPack = 8; //For the Hellema brand
var people = ["fardau", "wilfred", "jeroen", "teun", "arjan", "erik", "paul"];
var timtamsleftAfterEveryoneGetsOne = totalTimTamsinPack - people.length;
while(timtamsleftAfterEveryoneGetsOne-- > 0)
alert("The " + (timtamsleftAfterEveryoneGetsOne + 1 )+ "nd last tim tam goes to " + people[Math.floor(Math.random()*people.length)]);
@thepauljones
thepauljones / gist.js
Last active July 5, 2017 19:23
Used to generate the link in rtl slack to the debug portal
module['exports'] = function highFive(hook) {
// hook.io has a range of node modules available - see
// https://hook.io/modules.
// We use request (https://www.npmjs.com/package/request) for an easy way to
// make the HTTP request.
var request = require('request');
// The parameters passed in via the slash command POST request.
var params = hook.params;