File: dnaplotter

package info (click to toggle)
artemis 18.2.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 23,384 kB
  • sloc: java: 136,224; xml: 3,352; sh: 1,283; perl: 83; sql: 47; makefile: 28
file content (68 lines) | stat: -rwxr-xr-x 1,598 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#!/bin/bash -

#
# This script will start the Artemis circular plot on a UNIX system.
#

QUIET=no

usage () {
    echo "SYNOPSIS"
    echo "        DNA Plotter: DNA Image Generation Tool"
    echo "USAGE"
    echo "        $0 [options]"
    echo "OPTIONS"
    echo "        -t FILE      Read a template file"
    echo
    echo "EXAMPLES"
    echo "        % dnaplotter" 
    echo "        % dnaplotter -t <template file>" 
    echo
    echo "HOMEPAGE"
    echo "        http://www.sanger.ac.uk/science/tools/dnaplotter/"
    echo   
    
    exit 0
}

#
# Parse arguments.
#
TEMPLATE_FILE_ARG=
APPLICATION_PROPERTIES="-Djdbc.drivers=org.postgresql.Driver -Dartemis.environment=UNIX $SANGER_ARTEMIS_OPTIONS"
while test $# != 0
do
    case $1 in
	    -t)   	    TEMPLATE_FILE_ARG="$1 $2"; shift ;;
	    -D*)        APPLICATION_PROPERTIES="$APPLICATION_PROPERTIES $1" ;;
	    -quiet)     QUIET=yes ; APPLICATION_PROPERTIES="$APPLICATION_PROPERTIES -Drun_quietly=true" ;;
	    -help)      usage ;;
	    --help)     usage ;;
	    -h)         usage ;;
	    *)          usage ;;
    esac
    shift
done

#
# "-mx2g" sets the maximum amount of memory to use. 
# This may need to be increased when dealing with large files
#
if [[ "$ARTEMIS_JVM_FLAGS" = "" ]]
then
    FLAGS="-mx2g -ms100m -noverify"
else
    FLAGS="$ARTEMIS_JVM_FLAGS -noverify"
fi

if [[ "$QUIET" = "no" ]]
then
    echo "Starting DNA Plotter with arguments: $FLAGS $APPLICATION_PROPERTIES $TEMPLATE_FILE_ARG"
fi

java $FLAGS $APPLICATION_PROPERTIES -jar /usr/share/java/dnaplotter.jar $TEMPLATE_FILE_ARG
result=$?

exit $result

exit $?