summaryrefslogtreecommitdiff
path: root/zshrc
diff options
context:
space:
mode:
Diffstat (limited to 'zshrc')
-rw-r--r--zshrc13
1 files changed, 6 insertions, 7 deletions
diff --git a/zshrc b/zshrc
index ae2bc72..2f16e98 100644
--- a/zshrc
+++ b/zshrc
@@ -70,7 +70,6 @@ alias du='du -hc'
alias dus='du -S | sort -n'
alias free='free -m'
alias su='su - '
-alias x='startx'
alias rehash='hash -r'
alias eject='eject -v '
alias retract='eject -t -v '
@@ -157,10 +156,11 @@ function web () { $BROWSER "http://yubnub.org/parser/parse?command=$*" }
function pmem () { ps -o rss,comm -p $(pgrep $1) }
function dsync () { rsync -lprt --progress --stats --delete "$1/" "$2/" }
-function define () {
- dictionary="english"
- [[ "$2" != "" ]] && dictionary=$2
- echo "DEFINE $dictionary $1\nQUIT" | netcat dict.org 2628
+function x () {
+ if [[ -z "$DISPLAY" ]] && [[ $(tty) = /dev/tty1 ]]; then
+ startx
+ logout
+ fi
}
function scrot () {
@@ -177,8 +177,7 @@ function scrot () {
echo "Taking a screenshot..."
import -window root -quality 100 ~/$1-$timestamp.$format
echo "Generating a thumbnail..."
- cp ~/$1-$timestamp.$format ~/$1-$timestamp.th.$format
- mogrify -resize 15% ~/$1-$timestamp.th.$format
+ convert -resize 15% ~/$1-$timestamp.$format ~/$1-$timestamp.th.$format
echo "Saved as ~/$1-$timestamp.$format"
fi
}