Skip to content

Instantly share code, notes, and snippets.

View brannon's full-sized avatar

Brannon Jones brannon

  • GitHub Staff
  • Pacific NW
View GitHub Profile
@brannon
brannon / gist:ff0558305ecdb36d39f0b679784c43e5
Last active January 1, 2018 06:43
Packages for ChromeOS
Chromebrew packages:
- autoconf
- automake
- bind
- docbook
- glib
- go
- iptables
- jq
- libtool
@brannon
brannon / .vimrc
Created December 21, 2015 01:58
VIM Settings
" Most of this config was lifted from http://jsdelfino.blogspot.com/2010/11/my-vi-configuration-file.html
" vi-improved mode
set nocompatible
filetype on
filetype plugin on
filetype indent on
" cycle buffers without writing
set hidden
@brannon
brannon / gist:cbc7ff8fc67d970efb79
Last active August 29, 2015 14:19
Enable Remote PowerShell
Invoke-WebRequest https://gist.githubusercontent.com/brannon/39b23ef97d43732c8398/raw/0ebbc9d4d309e9f9ed4055dd5ed671a359c786bd/ConfigureRemotePowerShell.ps1 | Select -Expand Content | Set-Content -Encoding ASCII -Force .\ConfigureRemotePowerShell.ps1; powershell.exe .\ConfigureRemotePowerShell.ps1; Remove-Item .\ConfigureRemotePowerShell.ps1
@brannon
brannon / ConfigureRemotePowerShell.ps1
Last active September 30, 2016 15:42
Enable Remote PowerShell
# Configure a Windows host for remote management with Ansible
# -----------------------------------------------------------
#
# This script checks the current WinRM/PSRemoting configuration and makes the
# necessary changes to allow Ansible to connect, authenticate and execute
# PowerShell commands.
#
# Set $VerbosePreference = "Continue" before running the script in order to
# see the output messages.
#
@brannon
brannon / gist:771ffb94311eba8347ff
Created June 9, 2014 22:46
Dump error info in Go
// imports: strings, reflect, syscall
func dumpError(err error, depth int) {
indent := strings.Repeat(" ", depth*2)
errorType := reflect.TypeOf(err)
errorValue := reflect.ValueOf(err)
if errorType.Kind() == reflect.Ptr {
errorType = errorType.Elem()