This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Google Apps Script for use at https://script.google.com/ | |
// Use timed triggers to run the desired functions on a regular schedule (e.g. every 12 hours) | |
// search is a gmail search string, keepDays is the last N days of threads to keep in Inbox | |
function gmailAutoArchive(search, keepDays) { | |
var maxDate = new Date(); | |
maxDate.setDate(maxDate.getDate()-keepDays); | |
var threads = GmailApp.search(search); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -x | |
sudo dscl . create /Users/administrator IsHidden 1 | |
sudo mv /Users/administrator /var/administrator | |
sudo dscl . -create /Users/administrator NFSHomeDirectory /var/administrator | |
sudo dscl . -delete "/SharePoints/Administrator's Public Folder" | |
sudo defaults write /Library/Preferences/com.apple.loginwindow SHOWOTHERUSERS_MANAGED -bool FALSE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pre-req: Have a working go install :-) | |
# Increase open files limit (macOS default of 256 is too low) | |
ulimit -n 10000 | |
# Create paths | |
mkdir -p $GOPATH/src/github.com/terraform-providers/ | |
mkdir -p $GOPATH/src/github.com/hashicorp/ | |
# Get govendor and ensure $GOPATH/bin is in path |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Bootstrap script for use with http://boxstarter.org/ | |
# To use append the URL to the raw snippet to http://boxstarter.org/package/nr/url? | |
# (e.g. http://boxstarter.org/package/nr/url?https://gist.githubusercontent.com/mikemoate/0915288fff447b640cdb/raw/83b32099ea8f21d06604ae70003312b7492b8cd8/boxstarter-script-work) | |
# NOTE: You may see errors from some packages if you have already installed the software before using boxstarter. | |
# (some MSI's handle this badly and so exit with the wrong code, I've seen this for HipChat, RoyalTS, Virtualbox and Vagrant) | |
# Windows settings | |
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar | |
Set-TaskbarOptions -Size Small -Lock -Dock Bottom |