Skip to content

Instantly share code, notes, and snippets.

Jesse jeriley

Block or report user

Report or block jeriley

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View .bashrc
function open {
explorer .
function dynamo {
java -Djava.library.path=./DynamoDBLocal_lib -jar /c/dynamoDb/DynamoDBLocal.jar -sharedDb
function reset-me {
echo 'resting HEAD'
View CollapsedExample.cs
using Moq;
using NUnit.Framework;
using Should;
//and some other stuff
namespace WorkerTests
public class Worker_CreateThingFromContractTests
View keybase.txt
### Keybase proof
I hereby claim:
* I am jeriley on github.
* I am jeriley ( on keybase.
* I have a public key whose fingerprint is B38D 868C 4219 D39A 2090 E6EA 57F3 D2D9 5A72 BDC0
To claim this, I am signing this object:
jeriley / SalesforceChecksum.ts
Created Feb 20, 2018
Salesforce ID checksum ... now in typescript!
View SalesforceChecksum.ts
export class SalesforceChecksum
private lookup = {};
private checksumChars = Array.from("ABCDEFGHIJKLMNOPQRSTUVWXYZ012345");
for (var i = 0; i < 32; i++)
let value = (i >>> 0).toString(2);
jeriley / Checksum.cs
Created Feb 28, 2017
Salesforce ID checksum in C#
View Checksum.cs
public class Checksum
private Dictionary<string, char> _lookup = new Dictionary<string, char>();
private char[] _checksumChars = "ABCDEFGHIJKLMNOPQRSTUVWXYZ012345".ToCharArray();
public Checksum()
for (var i = 0; i < 32; i++)
var bit = Convert.ToString(i, 2).PadLeft(5, '0');
View jasmine-jquery-post-example.js
function buildIt($){
this.postIt = function(itemToChange){
$.post('giggle', function(data){
itemToChange.item = data.item;
jeriley / spark.bat
Created Feb 2, 2016
setting up Spark shortcut / reminders (windows)
View spark.bat
@echo do you have winutils or hadoop_home?
mkdir C:\tmp\hive
%HADOOP_HOME%\bin\winutils chmod 777 /tmp/hive
@echo does your path have a thing for spark?
cd C:\
jeriley / DbContextMockExtension.cs
Created Mar 23, 2015
DbContext Mocking example
View DbContextMockExtension.cs
namespace Moq.Context {
public static class DbContextMockExtension
public static Mock<AHContext> SetupPartOfTheContextWith<T>(this Mock<AHContext> mockContext, List<T> listOfT, Expression<Func<AHContext, DbSet<T>>> setupReturn) where T : BaseEntity
var queryable = listOfT.AsQueryable();
var mockSet = new Mock<DbSet<T>>();
jeriley / java-ish.xsl
Created Jan 7, 2015
V1 Meta to java classes
View java-ish.xsl
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE stylesheet
<!ENTITY mdash "&#8212;">
<xsl:stylesheet xmlns:xsl="" version="1.0">
<xsl:template match="/">
jeriley / Update Story Example.ps1
Last active Aug 29, 2015
V1Api example : powershell
View Update Story Example.ps1
$username = "admin"
$password = "admin"
$instance = "http://localhost/VersionOne.Web/"
$base64ed = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes($($username + ":" + $password)))
$storyId = "S-01001"
$story = GetStoryByID $storyId
UpdateAsset $story "<Asset><Attribute name='Description' act='set'>Descript Insert!</Attribute></Asset>"
#disabled because this will update a pile of stories -- be careful!
You can’t perform that action at this time.