File: monodoc-http-script

package info (click to toggle)
mono-tools 3.10-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 13,804 kB
  • ctags: 18,095
  • sloc: cs: 100,891; sh: 3,927; makefile: 2,039; xml: 126
file content (18 lines) | stat: -rwxr-xr-x 458 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash
export LANG=C
unset port

while test -z "$port" ; do
   port=$RANDOM
   if [ $port -lt 1025 ] || netstat -a -n | grep -q :$port ; then
      unset port
   fi
done

clear
echo -e "\n\nThe XSP web server is starting now. To view the monodoc pages, your"
echo -e "web browser will open http://localhost:$port/ now.\n\n"

(sleep 5; sensible-browser http://localhost:$port/) &

exec xsp4 --root /usr/share/monodoc/web --port $port --address 127.0.0.1