Accepting request 43747 from home:walery
Copy from home:walery/mc via accept of submit request 43747 revision 57. Request was accepted with message: Reviewed ok OBS-URL: https://build.opensuse.org/request/show/43747 OBS-URL: https://build.opensuse.org/package/show/Base:System/mc?expand=0&rev=12
This commit is contained in:
committed by
Git OBS Bridge
parent
bdfdad3702
commit
c83437be47
59
x11_browser
59
x11_browser
@@ -1,59 +0,0 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Call appropriate brower
|
||||
#
|
||||
# Copyright (c) 2001 Philipp Thomas <pth@suse.de>
|
||||
#
|
||||
# Borrowed heavily from url_handler.sh by Werner Fink <werner@suse.de>
|
||||
#
|
||||
|
||||
url="$1"
|
||||
method="${1%%:*}"
|
||||
|
||||
if test "$url" = "$method" ; then
|
||||
case "${url}" in
|
||||
*/*.htm|*/*.html) method=http ;;
|
||||
*/*.htmls) method=https ;;
|
||||
/*) if test -r "${url}" ; then
|
||||
method=file
|
||||
fi ;;
|
||||
*) if test -r "$PWD/${url}" ; then
|
||||
method=file
|
||||
url="$PWD/${url}"
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
case "$method" in
|
||||
file) url="${method}:$url" ;;
|
||||
*) url="${method}://$url" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
shift
|
||||
|
||||
case "$method" in
|
||||
file|http|https)
|
||||
http=
|
||||
type -p lynx >& /dev/null && http=lynx
|
||||
type -p links >& /dev/null && http=links
|
||||
type -p w3m >& /dev/null && http=w3m
|
||||
test -n "$DISPLAY" && type -p netscape >& /dev/null && http=netscape
|
||||
test -n "$DISPLAY" && type -p Netscape >& /dev/null && http=Netscape
|
||||
test -n "$DISPLAY" && type -p opera >& /dev/null && http=opera
|
||||
test -n "$DISPLAY" && type -p mozilla >& /dev/null && http=mozilla
|
||||
case "$http" in
|
||||
[nN]etscape|opera|mozilla) ($http -remote "openURL($url)" || $http "$url") >/dev/null 2>&1 & ;;
|
||||
lynx|w3m|links) exec $http "$url" ;;
|
||||
*)
|
||||
echo "No HTTP browser found."
|
||||
read -p "Press return to continue: "
|
||||
exit 0 # No error return
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*)
|
||||
echo "URL type \"$method\" not known"
|
||||
read -p "Press return to continue: "
|
||||
exit 0 # No error return
|
||||
;;
|
||||
esac
|
Reference in New Issue
Block a user