The proc is explained here
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
sudo -i | |
if [[ -d /etc/sudoers.d ]]; then | |
echo "ori ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/ori | |
chmod 440 !$ | |
chown root:root !$ #match the owner && perms of README | |
elif [[ -e /etc/sudoers ]]; then | |
echo "ori ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers | |
else | |
echo "Failed to add ori to sudoers" | |
fi |
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
from iTerm -> clipboard | |
>> pbcopy < file |
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
# copy from vim to XCLIPBOARD, using reg '+' (or '*') | |
"+yG |
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
gconftool-2 --set "/apps/metacity/general/button_layout" --type string ":minimize,maximize,close" |
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
alias ll='ls -lah --color=tty --time-style=long' | |
alias grep='grep --color=tty' | |
alias mydate='date "+%F %H:%M"' | |
alias olsblk='lsblk -o NAME,FSTYPE,LABEL,MOUNTPOINT,SIZE,TYPE ' | |
alias dv='dirs -v' | |
alias po='popd ' | |
alias pu='pushd ' | |
alias s='git status ' | |
alias xr='xrandr --verbose --output VGA1 --primary --mode 1920x1080' |
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
# vim: set filetype=sh : | |
# Purpose | |
# set environment variables for EC2_URL EC2_HOME JAVA_HOME CLASSPATH | |
# required by ec2-api-tools, used by other tools (e.g. vagrant) | |
# Usage: | |
# source this | |
# create local env.monsoon in a project's subdir defining: | |
# export AWS_PROJECT="MOCONS / rmjen" |
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
#!/usr/bin/env bash | |
# Author: Ori Tzoran, based on idea and gist by aaronzirbes (see evolution below) | |
# Tested on Mac OS X 10.10.2 (14C109) | |
set -e | |
## verify root runs this | |
[[ $(id -u) == 0 ]] || { echo need root; exit 1; } | |
#set -vx |