Skip to content

Instantly share code, notes, and snippets.

View roydondsouza's full-sized avatar

Roydon DSouza roydondsouza

View GitHub Profile
@roydondsouza
roydondsouza / AWSLambdaSimpleSMS.js
Created February 4, 2017 15:06 — forked from stevebowman/AWSLambdaSimpleSMS.js
AWS Lambda Function to send an SMS message via the Twilio API
console.log('Loading event');
// Twilio Credentials
var accountSid = '';
var authToken = '';
var fromNumber = '';
var https = require('https');
var queryString = require('querystring');
@roydondsouza
roydondsouza / merge.md
Created August 4, 2016 18:13 — forked from jt/merge.md
Merge a forked gist

If someone forks a gist and you'd like to merge their changes. Do this:

  1. clone your repo, I use the name of the gist

     git clone git://gist.github.com/1163142.git gist-1163142
    
  2. add a remote for the forked gist, I'm using the name of my fellow developer

     git remote add aaron git://gist.github.com/1164196.git
    
@roydondsouza
roydondsouza / gist:75cc65cb57e8982fb742d7e511c5519f
Created July 11, 2016 05:08 — forked from sl4m/gist:5091803
create self-signed certificate for localhost
# SSL self signed localhost for rails start to finish, no red warnings.
# 1) Create your private key (any password will do, we remove it below)
$ openssl genrsa -des3 -out server.orig.key 2048
# 2) Remove the password
$ openssl rsa -in server.orig.key -out server.key
@roydondsouza
roydondsouza / gist:6dc666f88e459a40bc4bf04b1ab8d51f
Created June 16, 2016 18:52 — forked from prime31/gist:5675017
Simple PHP script showing how to send an Android push notification. Be sure to replace the API_ACCESS_KEY with a proper one from the Google API's Console page. To use the script, just call scriptName.php?id=THE_DEVICE_REGISTRATION_ID
<?php
// API access key from Google API's Console
define( 'API_ACCESS_KEY', 'YOUR-API-ACCESS-KEY-GOES-HERE' );
$registrationIds = array( $_GET['id'] );
// prep the bundle
$msg = array