File: monodoc-http-script

package info (click to toggle)
mono-tools 2.6.2-3
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 10,524 kB
  • ctags: 15,712
  • sloc: cs: 85,697; sh: 3,622; makefile: 1,662; xml: 112; sql: 18
file content (18 lines) | stat: -rw-r--r-- 456 bytes parent folder | download
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 xsp2 --root /usr/lib/monodoc/web --port $port --address 127.0.0.1