Skip to content

Instantly share code, notes, and snippets.

View thefridge111's full-sized avatar

William Perry thefridge111

  • CommerceHub Inc.
  • Albany, NY
View GitHub Profile
@thefridge111
thefridge111 / javascript-constructor.js
Created January 18, 2018 20:18
Convenient method of creating objects in javascript so that you have 'safe' default values when you construct objects and that are easy to maintain. This method greatly reduced complexity in our app and allowed us to more easily model Java class behaviors. Hope this is useful for someone.
function SomeObject(data) {
var obj = this;
// Used as a generic setter where we arent doing any manipulation
function setter(value) {
return value;
}
function listSetter(values) {
var valueList = [];
@thefridge111
thefridge111 / github_issues_to_csv_v3.rb
Created December 2, 2015 14:26 — forked from kevinpschaaf/github_issues_to_csv_v3.rb
Exports Github issues to CSV (API v3)
require 'octokit'
require 'csv'
require 'date'
# Description:
# Exports Github issues from one or more repos into CSV file formatted for import into JIRA
# Note: By default, all Github comments will be assigned to the JIRA admin, appended with
# a note indicating the Github user who added the comment (since you may not have JIRA users
# created for all your Github users, especially if it is a public/open-source project:
#