Skip to content

Instantly share code, notes, and snippets.

Ben Holland hollandben

Block or report user

Report or block hollandben

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 opencensus-stackdriver-exporter-log.json
"response": {
"config": {
"headers": {
"Accept-Encoding": "gzip",
"User-Agent": "google-api-nodejs-client/0.7.2 (gzip)",
"Authorization": "Bearer AUTHENTICATED_BEARER_TOKEN",
"Content-Type": "application/json",
"Accept": "application/json"
# TODO: release new version of FileBot for Linux
# Download latest portable package
hollandben / task.js
Last active Apr 10, 2018
Mapping from one data structure to another
View task.js
function process (input) {
// Reduce over input to process an object where the key is the location and the value is the products
const tree = input
.reduce((output, o) => {
o.locations.forEach(location => {
if (output[location] === undefined) {
output[location] = [];
hollandben / .zshrc
Last active Feb 28, 2020
Configuration for ZSH with aliases
View .zshrc
# Path to your oh-my-zsh installation.
export ZSH=/Users/bholland/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
# Uncomment the following line to use case-sensitive completion.
hollandben / publish.js
Created Mar 23, 2016
Publishing to NPM via a script
View publish.js
'use strict';
const execSync = require('child_process').execSync;
const npm = require('npm');
const fs = require('fs');
const args = require('yargs').argv;
const uri = '';
console.log('args', args);
View angular-module-cleanup.js
import cloneDeep from 'lodash/cloneDeep';
import PayloadService from './payload.svc';
import StatsResource from '../resources/stats.rsc';
import DataTransformationService from '../../core-data-transformation/services/core-data-transformation.svc';
let $q, $timeout, statsResource, dataTransformationService;
const SUMMARY_RETRIEVAL_SERVICE_NAME = 'socialgrids.coreData.summaryRetrievalService';
class SummaryRetrievalService extends PayloadService {
hollandben / version.txt
Created Feb 2, 2016
GoPro Hero 3+ Black Edition
View version.txt
"info version":"1.1",
"firmware version":"HD3.11.03.03",
"wifi version":"",
"wifi bootloader version":"0.1.0",
"wifi mac":"d4d91924fff0",
"camera type":"HERO3+ Black Edition",
"camera serial number":"H3B+B051424FFF0",
View pre-push-safety-net
current_branch=$(git symbolic-ref HEAD | sed -e 's,.*/\(.*\),\1,')
if [ $protected_branch = $current_branch ]
read -p "You're about to push master, is that what you intended? [y|n] " -n 1 -r < /dev/tty
if echo $REPLY | grep -E '^[Yy]$' > /dev/null
hollandben / gist:7badd7c9ecdf81f16602
Created Jan 22, 2015
Installing Ubuntu on Chromebook Pixel
View gist:7badd7c9ecdf81f16602
  1. Install the Crouton chrome extension
  2. Open a shell window and run sudo sh ~/Downloads/crouton -r trusty -t xiwi,unity,touch,extension.
  3. When setup is complete, run sudo startunity. It should say "Cannot connect to extension, retrying...". If a new window doesn't open, then click the Crouton browser extension button
  4. A new window should appear with Ubuntu installed.
View gist:66038f2e94d953f52fe4
@if $debug-mode == true{
* Enable this stylesheet to visually detect any improperly nested or
* potentially invalid markup, or any potentially inaccessible code.
* Red == definite error
* Yellow == double-check
You can’t perform that action at this time.