Skip to content

Instantly share code, notes, and snippets.

View pzurek's full-sized avatar

Piotr Zurek pzurek

View GitHub Profile
@ThisIsMissEm
ThisIsMissEm / handler.js
Created November 25, 2014 18:53
The better way to execute Go on Amazon Lambda (see: http://blog.0x82.com/2014/11/24/aws-lambda-functions-in-go/)
var child_process = require('child_process');
exports.handler = function(event, context) {
var proc = spawn('./test', [ JSON.stringify(event) ], { stdio: 'inherit' });
proc.on('close', function(code){
if(code !== 0) {
return context.done(new Error("Process exited with non-zero status code"));
}
@elithrar
elithrar / stripe-config.js
Created November 27, 2013 00:40
Example Stripe Checkout - Custom Integration for #stripe
// Disable the payment/submit button until everything has loaded
// (if Stripe fails to load, we can't progress anyway)
$(document).ready(function() {
$("#payment-button").prop('disabled', false)
})
var handler = StripeCheckout.configure("customButtonA", {
key: '<yourpublishablekey',
token: function(token, args){
var $input = $('<input type=hidden name=stripeToken />').val(token.id);
using System;
using System.Linq;
using Newtonsoft.Json.Linq;
namespace FacebookChallenge
{
class Program
{
static readonly string accessToken = "GET YOUR OWN FOO";
static readonly string baseUrl = "https://graph.facebook.com/{0}/{1}?access_token={2}";