Skip to content

Instantly share code, notes, and snippets.

View sohjsolwin's full-sized avatar

Josh Wilson sohjsolwin

View GitHub Profile
@sohjsolwin
sohjsolwin / script.js
Created August 29, 2014 17:28
Dynamically add items to a webpage header
var tempChild = {};
var head = document.head;
if (!head) head = document.getElementsByTagName('head')[0];
var dynamicloads = head.getElementsByClassName('dynamicload');
for (var i = 0; i < dynamicloads.length; i++) {
dynamicloads[0].parentNode.removeChild(dynamicloads[0]);
}
@sohjsolwin
sohjsolwin / InstallCinnamonCrouton
Created July 6, 2013 13:49
Steps to install and setup a cinnamon flavored crouton on a Chromebook Pixel
# The next command will install a [raring] based ubuntu
# chroot, named [cinnamon] into the default directory
# with the targets [core], [cli-extra], [touch], and [keyboard]
sudo crouton -n cinnamon -r raring -t core,cli-extra,touch,keyboard
# Supply your new username and password like normal, and
# once that finishes, enter the chroot with:
sudo enter-chroot -n cinnamon
@sohjsolwin
sohjsolwin / startcinnamon
Created July 5, 2013 12:56
startcinnamon script for launching cinnamon for a ChromeOS Chroot
APPLICATION="${0##*/}"
USAGE="$APPLICATION [options]
Wraps enter-chroot to start a Mint session.
By default, it will log into the primary user on the first chroot found.
Options are directly passed to enter-chroot; run enter-chroot to list them."
exec sh -e "`dirname "$0"`/enter-chroot" "$@" startx /bin/bash gnome-session-cinnamon