Skip to content

Instantly share code, notes, and snippets.


Phill Pafford phillpafford

View GitHub Profile
View gist:605f02c0b6dc6cf66958a32024fa0ba8
## idea is to run this cron job at 12:59 PM daily to move the existing access and error logs and reload nginx
CURRENT_DATE=$(date +"%Y-%m-%d")
View git-checkout-latest-tag
#!/usr/bin/env bash
# check out latest semvar tag from git master repo
## exit if script fails
set -e
## get current branch checked out
CURRENT=`git rev-parse --abbrev-ref HEAD`
View logstash.mapping
"logstash-2018.11": {
"mappings": {
"doc": {
"_meta": {
"version": "6.4.2"
"dynamic_templates": [
"fields": {
View gist:09ee6e4e176670fb66fa75e264a8de99
phillpafford /
Created May 26, 2016 — forked from bzerangue/
Binding and Unbinding to Active Directory from Mac OS via Command Line

Binding and Unbinding to Active Directory from Mac OS via Command Line

  • Open the Terminal Application
  • Type in sudo -i and type in your Mac Administrator account password. sudo gives you root level or administrator level privileges.

To View current Active Directory Settings

dsconfigad -show

To Unbind a Computer from an Active Directory Domain

View gist:c2a3bdb296270f5b3e14
Verifying that +phillpafford is my blockchain ID.
# $1 => Slack hook URL
# $2 => Channel name
# $3 => URL to web repo browser for base project
# Debugging output in /tmp/stash_slack.txt

This is a short article on how we integrate stash and slack in openmind

First of all i assume you have:

  • a working stash installation
  • a repository you to notify slack on pushes
  • stash user with administration priviledges
  • full access to the server (linux) where stash is installed on
  • a team configured on slack
  • slack user with administration priviledges
phillpafford / speedmail.command.line.scpt
Created Sep 15, 2014
Speed up by vacuuming the Envelope Index
View speedmail.command.line.scpt
Speed up by vacuuming the Envelope Index
Code from:
Originally by "pmbuko" with modifications by Romulo
Updated by Brett Terpstra 2012 <>
tell application "Mail" to quit
set sizeBefore to do shell script "ls -lah ~/Library/Mail/V2/MailData | grep -E 'Envelope Index$' | awk {'print $5'}"
do shell script "/usr/bin/sqlite3 ~/Library/Mail/V2/MailData/Envelope\\ Index vacuum"

Keybase proof

I hereby claim:

  • I am phillpafford on github.
  • I am phillpafford ( on keybase.
  • I have a public key whose fingerprint is DF23 E529 F9B6 9327 3E01 1D82 FB9D EBB3 407A 1138

To claim this, I am signing this object:

You can’t perform that action at this time.