Skip to content

Instantly share code, notes, and snippets.

View raddevon's full-sized avatar

Devon Campbell raddevon

View GitHub Profile
@derekseymour
derekseymour / freshdesk_sso.js
Last active June 17, 2020 15:59
Freshdesk Single Sign On URL - Node.js
var crypto = require('crypto');
/**
* Generates and returns a Freshdesk Single Sign On URL
* {@link https://gist.github.com/derekseymour/26a6fe573c1274642976 Gist}
*
* @author Derek Seymour <derek@rocketideas.com>
* @param {String} name - The name of the user logging in.
* @param {String} email - A valid email address to associate with the user.
@asiermarques
asiermarques / gist:21431cc61e90d57ac927
Last active August 3, 2016 22:57
openlayers draggable "marker"
var initMap = function(){
var Lon = -2.93 ;
var Lat = 43.2629642;
var Zoom = 14;
var EPSG4326 = new OpenLayers.Projection( "EPSG:4326" );
var EPSG900913 = new OpenLayers.Projection("EPSG:900913");
var LL = new OpenLayers.LonLat( Lon, Lat );
var XY = LL.clone().transform( EPSG4326, EPSG900913 );
// example function where arguments 2 and 3 are optional
function example( err, optionalA, optionalB, callback ) {
// retrieve arguments as array
var args = [].slice.call(arguments);
// first argument is the error object
// shift() removes the first item from the
// array and returns it
err = args.shift();
@tdominey
tdominey / gist:6066495
Created July 23, 2013 21:52
Display siblings of album from parent set
<koken:parent>
<p>
<strong>From the set:</strong> <koken:link title="View {{ album.title }}">
{{ album.title }}</koken:link>
</p>
<p>
<strong>Other albums in this set:</strong>
<koken:loop>
<koken:link>{{ album.title }}</koken:link>
</koken:loop>
@collinschaafsma
collinschaafsma / rails-grunt.js
Created April 10, 2012 03:43
Grunt config for Rails
// This is the main application configuration file. It is a Grunt
// configuration file, which you can learn more about here:
// https://github.com/cowboy/grunt/blob/master/docs/configuring.md
//
module.exports = function(grunt) {
grunt.initConfig({
// The clean task ensures all files are removed from the dist/ directory so
// that no files linger from previous builds.