This file contains hidden or 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
### Keybase proof | |
I hereby claim: | |
* I am alampros on github. | |
* I am alampros (https://keybase.io/alampros) on keybase. | |
* I have a public key ASBxVdHSievxMIeIQPtfWQ8tNs2PW4L-cMw3AIlu7ht1nwo | |
To claim this, I am signing this object: |
This file contains hidden or 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/bash | |
# Searches for given expression in process list, highlights matches, and includes the ps header row. | |
ps -Al | grep -vE "grep|pss" | grep -E "PID|$1" | column -tx | grep -A 9999 -B 9999 -E "$1" --color=auto |
This file contains hidden or 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
--Originally posted by "kiodane" at http://forums.macrumors.com/showthread.php?t=383969 | |
tell application "System Preferences" | |
set current pane to pane "com.apple.preference.keyboard" | |
end tell | |
tell application "System Events" | |
if UI elements enabled then | |
tell tab group 1 of window "Keyboard" of process "System Preferences" | |
click checkbox "Use all F1, F2, etc. keys as standard function keys" | |
if (do shell script "defaults read -g com.apple.keyboard.fnState") = "1" then |
This file contains hidden or 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
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" | |
BLUE="\[\033[0;34m\]" | |
LIGHT_RED="\[\033[1;31m\]" | |
LIGHT_GREEN="\[\033[1;32m\]" | |
WHITE="\[\033[1;37m\]" | |
LIGHT_GRAY="\[\033[0;37m\]" | |
LIGHT_BLUE="\[\033[1;36m\]" | |
COLOR_NONE="\[\e[0m\]" |
This file contains hidden or 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/bash | |
# create variables | |
while read L; do | |
k="`echo "$L" | cut -d '=' -f 1`" | |
v="`echo "$L" | cut -d '=' -f 2`" | |
export "$k=$v" | |
done < <(grep -e '^\(title\|artist\|album\|stationName\|pRet\|pRetStr\|wRet\|wRetStr\|songDuration\|songPlayed\|rating\|coverArt\)=' /dev/stdin) | |
case "$1" in |