slitaz-tools rev 942

browser: add poor man browser (for gtkonly)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu May 14 12:55:55 2015 +0200 (2015-05-14)
parents 4475062064ee
children 3be081525506
files tinyutils/browser
line diff
     1.1 --- a/tinyutils/browser	Mon Apr 27 12:14:05 2015 +0200
     1.2 +++ b/tinyutils/browser	Thu May 14 12:55:55 2015 +0200
     1.3 @@ -9,6 +9,11 @@
     1.4  
     1.5  EXEC="exec setsid $BROWSER"
     1.6  
     1.7 +[ "$(which $BROWSER)" ] || case "$1" in
     1.8 +file://*)
     1.9 +	exec xterm -e "sh -c \"sed 's/<[^>]*>//g;s/&lt;/</g;s/&gt;/>/g;s/&amp;/\\&/g' < ${1#file://} | uniq | less\""
    1.10 +esac
    1.11 +
    1.12  if [ -z "$XAUTHORITY" ]; then
    1.13  	# console session
    1.14  	EXECT="$BROWSER"