Instantly share code, notes, and snippets.

View keybase.md

Keybase proof

I hereby claim:

  • I am briangordon on github.
  • I am brian (https://keybase.io/brian) on keybase.
  • I have a public key ASA8l7cfD9ar5ZcXq_MkGZCVjV9B9eo9l1dpQ5D4LsgOsAo

To claim this, I am signing this object:

View git-review-aliases.txt
*****************************************************************************************************************************
Introduction
The code review workflow that I prefer is to check out a feature branch, then `reset --soft` to move the branch HEAD to
just before the changes. That way I still have all of the changes in my working copy, and those exact changes are staged
for commit. My IDE will highlight the changed lines right in the editor and let me click the gutter to view a quick diff.
This is incredibly useful. But problems arise when develop has been merged into a running PR, bringing along a whole bunch
of other unrelated changes that have already been reviewed. I don't want all of those other changes to be highlighted in
my IDE, but I do want them in my working copy.
View cellfactorytest.scala
package cellfactory
import javafx.application.Application
import javafx.collections.FXCollections
import javafx.scene.control.ListView
import javafx.scene.layout.StackPane
import javafx.scene.{Scene, control => jfxsc}
import javafx.stage.Stage
import javafx.util.Callback
View gist:df79f7cd3750ac9fe1109553c8262aee
case class HalfLife(lowerBoundHours: BigDecimal, upperBoundHours: BigDecimal, meanHours: BigDecimal)
def computeMean(lowerBoundHours: BigDecimal, upperBoundHours: BigDecimal): BigDecimal = {
// TODO linear interpolation is terrible here. These are exponential quantities.
(lowerBoundHours + upperBoundHours) / 2
}
// Hack to get pureconfig to create instances of HalfLife without an explicit mean-hours value.
import com.typesafe.config.{ConfigObject, ConfigValueFactory}
import pureconfig.ConfigReader
View animal-verbs.txt
Ape his behaviors
Badger her about
Bat your eyelids
Bear fruit
Buck the system
Buffalo him into
Bug him about
Carp about
Chicken out
Clam up
View list-processes.ps1
while($true) {
Get-Process | ? {$_.StartTime -gt (Get-Date).AddMinutes(-1)} | Select-Object ProcessName,Description,Path >> out.txt
sleep 0.01
}
View wolfenstein-the-old-blood-headers.txt
This file has been truncated, but you can view the full file.
View eve-pathfinder.cpp
#include <iostream>
#include <iomanip>
#include <fstream>
#include <sstream>
#include <string>
#include <vector>
#include <unordered_map>
#include <sys/time.h>
// We specify the total number of systems explicitly so that we can initialize data structures before reading in the whole csv file.
View keybase.md

Keybase proof

I hereby claim:

  • I am briangordon on github.
  • I am brian (https://keybase.io/brian) on keybase.
  • I have the public key with fingerprint 41AA 1387 FA3D 5EAC 4F4B  18EE AE46 EFC0 2F3E 2BA8

To claim this, I am signing this object:

View gist:8869639
a,10144200
abandon,15323
ability,51476
able,103171
abortion,18925
about,208550
above,23866
abroad,8788
absence,13597
absolute,9622