Skip to content

Instantly share code, notes, and snippets.

Avatar

chaosbunker

View GitHub Profile
@chaosbunker
chaosbunker / set-wallpaper.py
Created Mar 1, 2016 — forked from gregneagle/gist:6957826
Using PyObjC and NSWorkspace to set the desktop picture. I am such a hypocrite!
View set-wallpaper.py
#!/usr/bin/python
'''Uses Cocoa classes via PyObjC to set a random desktop picture on all screens.
Tested on Mountain Lion and Mavericks.
See:
https://developer.apple.com/library/mac/documentation/cocoa/reference/applicationkit/classes/NSWorkspace_Class/Reference/Reference.html
https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Foundation/Classes/NSURL_Class/Reference/Reference.html
@chaosbunker
chaosbunker / gnuize.sh
Last active Jan 13, 2016 — forked from clayfreeman/gnuize.sh
GNU-ize Mac OS X El Capitan
View gnuize.sh
#!/bin/bash
# install homebrew
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master$
brew doctor
# Install required packages from Homebrew
brew tap homebrew/dupes
brew install coreutils binutils diffutils ed findutils gawk gnu-indent gnu-sed \
@chaosbunker
chaosbunker / Install_XCode.applescript
Created Jan 12, 2016 — forked from trinitronx/Install_XCode.applescript
Script to automate XCode installation. Tested on OSX 10.8.4 Mountain Lion. I feel like using the UI element hierarchy is quite disgusting, but it works for now...
View Install_XCode.applescript
-- Function to select a menu item
-- We will use this to trigger the search box for the App Store
on do_menu(app_name, menu_name, menu_item)
try
-- bring the target application to the front
tell application app_name
activate
end tell
tell application "System Events"
tell process app_name
You can’t perform that action at this time.