Skip to content

Instantly share code, notes, and snippets.

View cerdman's full-sized avatar

colin b. erdman cerdman

  • TriNetX Inc.
  • United States
View GitHub Profile
<!DOCTYPE html>
<html ng-app="myApp">
<head>
<title>Directives</title>
</head>
<body>
<div ng-controller="ChildController as child">
<button type="button" ng-click="child.sayMe()">Say me!</button>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.0-rc.1/angular.min.js"></script>
<!DOCTYPE html>
<html>
<head>
<script src="http://d3js.org/d3.v3.min.js"></script>
<script src="https://cdn.rawgit.com/lodash/lodash/3.5.0/lodash.min.js"></script>
<script src="https://code.jquery.com/jquery.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.15/angular.min.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
@cerdman
cerdman / index.html
Last active August 29, 2015 14:22
Angular Formly Example// source http://jsbin.com/ludiqa
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-2.1.1.min.js"></script>
<!-- Twitter bootstrap -->
<link href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css" rel="stylesheet">
<!-- apiCheck is used by formly to validate its api -->
<script src="http://rawgit.com/kentcdodds/apiCheck.js/master/dist/api-check.min.js"></script>
#!/usr/bin/env bash
if [ "$#" -ge 2 ]
then
DBNAME="$1"; shift
PREFIX="$1"; shift
else
echo "usage: mysql-dump-like.sh <database> <table_prefix> [<mysql_options...>]"
exit 1
fi
@cerdman
cerdman / bag.py
Created May 24, 2015 02:41
Python bag collection class implementation
"""
original src credit: http://code.activestate.com/recipes/259174-bag-collection-class/
"""
from operator import itemgetter
from heapq import nlargest
class bag(object):
def __init__(self, iterable=()):
self._data = {}
#!/bin/sh
# Make sure only root can run our script
if [ "$(id -u)" != "0" ]; then
echo "This script must be run as root" 1>&2
exit 1
fi
# Load configuration
. /etc/route53/config

Keybase proof

I hereby claim:

  • I am cerdman on github.
  • I am cerdman (https://keybase.io/cerdman) on keybase.
  • I have a public key whose fingerprint is 5F93 C5F5 CFFA F505 8B8F CE6E 460A 92FA 661D 82DE

To claim this, I am signing this object:

describe('Profile | Clipboard | Finder |', function() {
beforeEach(module('profile.clipboard.finder'));
beforeEach(module('ui.router'));
describe('ClipboardFinderCtrl |', function() {
var ctrl, scope, httpBackend, finder;
beforeEach(inject(function($rootScope, $controller, Finder, $httpBackend) {
scope = $rootScope.$new();
scope.main = {};
// Mocked Service
angular.module('mock.users', []).
factory('UserService', function($q) {
var userService = {};
userService.get = function() {
return {
id: 8888,
name: "test user"
}
require 'json'
require 'open-uri'
require 'csv'
require 'date'
# Github credentials to access your private project
USERNAME="myusername"
PASSWORD="mypassword"
# Project you want to export issues from