This file is indexed.

/usr/share/doc/squeak-plugins-scratch/scripts/run-scratch is in squeak-plugins-scratch 1.4.0.2~svn.r83-2.1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
#!/bin/sh
# File:            scratch
# Description:     Script to start the Squeak VM binary with the scratch image
# Original Author: Bert Freudenberg
# Adapted by:      Miriam Ruiz

VM_VERSION=`find /usr/lib/squeak/ -name "squeakvm" -type f|cut -f5 -d"/"`
SQ_DIR=/usr/lib/squeak/$VM_VERSION
VM="$SQ_DIR/squeakvm"
VMOPTIONS="-encoding UTF-8 -vm-display-x11 -xshm -plugins /usr/lib/scratch/plugins/:$SQ_DIR/"
IMAGE="/usr/share/scratch/Scratch.image"
IMOPTIONS=""
DOCUMENT=""
WRAPPER=""

#set to 1 to work around OLPC bug #8008
export SQUEAK_FAKEBIGCURSOR=0

# default directories (used if not running as Sugar activity)
[ -z "$SQUEAK_SECUREDIR" ] && export SQUEAK_SECUREDIR="$HOME/.scratch/private"
[ -z "$SQUEAK_USERDIR" ] && export SQUEAK_USERDIR="$HOME/Scratch"

[ ! -d "$SQUEAK_SECUREDIR" ] && mkdir -p "$SQUEAK_SECUREDIR" && chmod 700 "$SQUEAK_SECUREDIR"
[ ! -d "$SQUEAK_USERDIR" ] && mkdir -p "$SQUEAK_USERDIR"

usage()
{
    echo "Usage: scratch [--param value] [-vmopt value] [arg value]"
    echo "       where --param is --vm, --image, or --document;"
    echo "       -vmopt is an option passed to the Squeak VM;"
    echo "       and args are passed to the Squeak image."
}

while [ -n "$1" ] ; do
	if [ -z "$2" ] ; then
	        usage
		exit -1
	fi
	case "$1" in
	        --help)
			usage
 			exit
			;;
	        --document)
			case "$2" in
			    /*) DOCUMENT="$2"
				;;
			    *) DOCUMENT="$PWD/$2"
				;;
			esac
 			shift
			;;
	        --image)
			case "$2" in
			    /*) IMAGE="$2"
				;;
			    *) IMAGE="$PWD/$2"
				;;
			esac
 			shift
			;;
	        --vm)
			case "$2" in
			    /*) VM="$2"
				;;
			    *) VM="$PWD/$2"
				;;
			esac
 			shift
			;;
		-*) VMOPTIONS="$VMOPTIONS $1 $2"
			shift
			;;
		*)  IMOPTIONS="$IMOPTIONS $1 $2"
			shift
			;;
	esac
	shift
done

# do not crash on dbus errors
export DBUS_FATAL_WARNINGS=0

# make Compose input methods work
[ -z "$LC_ALL" ] && export LC_ALL="$LANG"

# if pulseaudio is running, fall back to OSS
if pulseaudio --check 2>/dev/null ; then
    VMOPTIONS="$VMOPTIONS -vm-sound-oss"
    if padsp true 2>/dev/null ; then
        WRAPPER=padsp
    fi
fi

# VM, Image, and Document are non-optional
# Document has to be present even if empty for IMOPTIONS to work
echo Executing: $WRAPPER "$VM" $VMOPTIONS "$IMAGE" "$DOCUMENT" $IMOPTIONS
exec $WRAPPER "$VM" $VMOPTIONS "$IMAGE" "$DOCUMENT" $IMOPTIONS