Skip to content

Instantly share code, notes, and snippets.

View lorddev's full-sized avatar
🎻
likes music

Aaron lorddev

🎻
likes music
View GitHub Profile
git branch --merged | egrep -v "(^\*|master|main|dev|develop)" | xargs git branch -d
git branch -r --merged | grep -v master | grep -v main | grep -v dev | grep -v develop | sed 's/origin\///' | xargs -n 1 git push --delete origin
git branch --merged | egrep -v "(^\*|master|main|dev|develop)" | xargs git branch -d
git branch -r --merged | grep -v master | grep -v main | grep -v dev | grep -v develop | sed 's/origin\///' | xargs -n 1 git push --delete origin
A0RAGgAgSBGzVNwCxS6JMEyKYxKWIekZVTUNVF2DaBtV6ZtEGiepziHFOononVRKOiiVLKTiIaQ0EVK4SNJGSD5KxUiJOinipVRKzASlm5LspMpPkKEolpLKU2Kqqqso2Qop6qtUitZKpeAtqLgLKu1V/kKqwZAiHQYWi/QYwmQkLgubpfRZUkaTOK3SaqkUei2Varao26RqN6rfiOFItRzqOSnTKddRajuVvkuV8VLVeapiPVLaL5VSr9hPKMBACrC2n+Cgsw3YJXw/CQ7SHHNmswmCjXFwe7YRfEGeR53UggcGeT9pCbeJ2qfj0LQe8JmkxIzoGcAjL52kANGdggm9BZRAkEzwfgLmNSXqTdM0TVMUNNSGxj9J5zUlGmS9TvUjqTTwRVHqi5zU5jUlGmS9TvUjqTTwRVHqi5zgeU2JBlmvU/1IKg18UZT6ImcTHHS2AbuE7ycE3+AG7BI+KUO6pBsg77tgJxZ9QxGsBzZhVB1a1fuJErem2LzCd9K7FFPmUZtmNkkJpgRGkEzwfpLOa0r4G2S9TvUjqTTwRVGf1OY1JfwNsl6n+pFUGviiqE/wvKaEv0HW61Q/kkoDXxT12cQFmR0IkgneT8C8YpLOKya1ecUEzytmk5Zwk0sb84piNtETN7C2n6jZZaHQmQx8AqMFmqUAV8QNPHGgf6g6anZZCQNwcDsO9A9VpzkFdaJml4VC14FLqYgbePIQA6ui/qjZZSUMwMHtPMTAqqg/yObAUOEnsNEaWgVYRdzAEwf6hypYFfVHzS4rYQAObseB/qEKVkX9QTYH2Uw6VUXcwJOHGFgV9UfNLithAA5u5yEGVkX9oSKbA4NsJg67bbWKuIEnDzG6pFP+o2aXlTAAB7fzEKNLOuU/MFRkc2CQxcQhmuawzQifONA/VOmSTvmPml1WwgAc3I4D/UOVLumU/8AgqTSnKHwnsIQYCgN9VMQNPHmIgVVRf9TsshIG4OB2HmJgVdQfKjzNgaEWvpNuIDy60puv+Uwc6B+qdEmn
@lorddev
lorddev / index.html
Last active August 5, 2018 19:16
qmjwLO
<link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet">
<div class="container-fluid">
<div class="row justify-content-center vertical-center">
<div class="col-4">
<p>@{<br/> &nbsp; // <em><i></i> Aaron Lord</em> web developer since 1998<br/>&nbsp; // Northern California, USA</p>
<p>&nbsp; // ASP.NET, Web API<br/> &nbsp; // C#, JavaScript, SQL<br/> }
</p>
</div>
@lorddev
lorddev / reformed-freethought.md
Created July 30, 2018 03:39
This is just a draft of some thoughts I've been working on. Not ready to publish.

How Reformed Theology taught me to be a Freethinker

Free Will is a Myth

One of the first Calvinist authors I read thoroughly was Jonathan Edwards. He was much derided in my high school American Lit class for the hellfire of "Sinners in the Hands of an Angry God", but he wrote hundreds of other books and sermons as well. His Freedom of the Will is an epic logical tome of metaphysics, in which it is explained that we do things because of our nature, and our wills are bound to that nature. In Calvinist speak this deals with the Sovereignty of God and the depravity of man. Despite the fact of our moral instincts, there are sociopaths who lack this instinct on one hand, and on the other none of us complies with our instinctual morals perfectly (white lies, outbursts of rage in an otherwise gentle soul, etc.)

But neuroscience shows that things we do are a product of biology, chemistry, physics. I have some disagreements with Sam Harris, but this area in particular is his expertise.

Natural Revelation,

@lorddev
lorddev / app.localize.js
Created July 5, 2018 23:42
JavaScript time localization for .NET MVC
// In JS:
// Base namespace
var app = app || {};
$.extend(true, app, {
localize: {
/**
* Local time; see http://blog.gauffin.org/2012/11/displaying-datetime-using-the-user-timezone-in-asp-net-mvc/
*/
init: function () {
public static class UriExtensions
{
public static void AppendPath(this UriBuilder b, string addPath)
{
var path = b.Path;
if (path.EndsWith("/"))
{
path = path.TrimEnd('/');
}
@lorddev
lorddev / MvcMockHelpers.cs
Created March 2, 2018 18:01
Mock context stuff for unit testing controllers
using System;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Web;
using System.Web.Mvc;
using System.Web.Routing;
using Moq;
namespace UnitTests
{
@lorddev
lorddev / TempTracker.cs
Created February 22, 2017 18:18
Temp Tracker for Interview Cake
public class TempTracker
{
// For mode
// Array of 0s at indices 0..110
private readonly int[] _occurrences = new int[111];
private int _maxOccurrences;
// For mean
private int _totalNumbers;
@lorddev
lorddev / gist:2f8a194f01494b63a3c6af1679659521
Created February 20, 2017 22:17
Guardian druid physical vs. magic damage for Mark of Ursol
dmfI1aqibQuTiuOCjuOYNqqPAuuiNIc1QeOIxjqvZscDlsAxus)cbLmmj4yuQwMGQNHGQPHsLRjaTnbW3qH04iLQohPuzDOqmpusLUhPyFKsjhebSquk9qsKjIsYfjLSruk(ikv1ijLsDssuRerVebLYmfuUjkvzNOGFIsmubIJkqLYsfqpLitfHUkPuSvuOkFfbfNfLuXBrGUlcYEPQ)kidgomQwmj0JjvtMOUSuBMs5ZOOrtbNwsRgLu1RjbMTOUTeTBH(TidNqwovEobthPRtrBNs8Dusz8KGopHA9Oqv9EbkZxGk5(cK2VAVDprVe3t0t9scEPWTs4wlyTGxQ0lj7LK9e9smDjwZlPnbXlPqwSztOPEgulynGEjXSyZMqt9mOs4fiCVexNwT0eDvMmBh7LKBpdQ2l4LeeX1Bpd29scD2wqs1i1lXwwisKf2ZlzORmnq9SHDmQ2hWcmQ2R9AN2vGDAp7yN27TPYoT3lLtCzprVeLN7i1t0lvAMPvprp1t9sYvB2Q6MzQyprVuPzMw9e9up1l5s52t0lvAMPvprp1t9s2460Ak6j6LknZ0QNON6PEjrwer55os9e9sLMzA1t0t9uVKJR3EIEPsZmT6j6PEQxYuOdPN5ccEf9uVKRzwtrIIf1EjzXrEzvNPlzkYlzqSIUQCqscvAnf9sgeRORkhgxG6LesoQxYGyfDvzVuRqr8OCl7zRxsXKtUDSyZMqt9my3lXLLR0AkYZHOUktMTtWt0t9svzVeRkzsuSOwWlzqSIUQSuYrzVKC7LKBb9okxJm9sYvbwVzuNwT0EjEo7LIMLeDvMmBNGNb7EjwRktn4zd7cybcpafSZOmk70(aYo7SJDEBQSlGEQxs3t0ZGDprVKIjNC7ukLtoprpd29muWZq4Egk4zGW9muWZa78my3t9sCDAnff8e9s1yL6j6LKtH0nfOPspB9s6Mc0uPxsvvvvvvvvvvvvvvvvvvvDsv1HsSWaBuM9hSeeIkZcdsdv1jvvvvvvvvvvvvvv