#--------------------------------------------------------------------------------
# Get / Head
#
-alias Head="lynx -dump -head -width=0"
-alias Get="lynx -source -width=0"
+#if which lynx &> /dev/null; then
+ alias Head="lynx -dump -head -width=0"
+ alias Get="lynx -source -width=0"
+#fi
#--------------------------------------------------------------------------------
# bc
opt="$opt --max_download_rate 150 --max_files_open 0"
alias torrent="btdownloadcurses.py $opt"
-
alias torrentdir="btlaunchmanycurses.py $opt"
elif which btdownloadcurses &> /dev/null; then
}
nb-radio-play() {
- local radios="
+ local radios="\
1 | FranceInter | http://www.tv-radio.com/station/france_inter_mp3/france_inter_mp3-128k.m3u
2 | Indie | http://107.155.126.42:17160/listen.pls
3 | FranceInof | http://players.creacast.com/creacast/france_info/playlist.m3u
4 | FranceCulture | http://www.tv-radio.com/station/france_culture_mp3/france_culture_mp3-128k.m3u
+
+Choose one > \
"
- read -s -p "$radios"
- test $REPLY -gt 0 2> /dev/null || return
- #echo -e "$radios" | awk 'BEGIN {$FS=" | "} $1 == '$REPLY' {print $1"."$2"."$3"."$4}'
- awk -F '|' '$1 == '$REPLY' {print $3; exit}' <<< "$radios" | sed 's/^ //' | xargs -r mplayer
+ read -p "$radios"
+ test -z "$REPLY" 2>/dev/null && return
+ awk -F '|' '$1 == '$REPLY' {print $3; exit}' <<< "$radios" | sed 's/^ //' | xargs mplayer 2>/dev/null
}
alias nb-img2jpg='convert -strip -interlace Plane -gaussian-blur 0.05 -quality 85%'