File: monodoc-http-script

package info (click to toggle)
mono-tools 2.10-6
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 13,012 kB
  • sloc: cs: 97,611; sh: 3,737; makefile: 1,880; xml: 128; sql: 18
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