16 ?
*) echo "The path must start with a \`/'";;
18 echo OK
, using default value.
24 # Create the directory if it doesn't exist. Exit if it can't be created.
26 if [ ! -d "$1" ]; then
27 mkdir
-p "$1" || die
"Can't create $1 directory!"
33 printf "[yes/no] >>> "
44 echo Testing the filer...
47 die
"Filer doesn't work! Giving up..."
54 **************************************************************************
56 Where would you like to install the filer?
57 Normally, you should choose (1) if you have root access, or (2) if not.
60 2) Inside my home directory
62 4) Specify paths manually
72 1) APPDIR
=/usr
/local
/apps
76 2) APPDIR
=${HOME}/Apps
78 if [ ! -d ${HOME}/man
]; then
88 4) echo "Where should the ROX-Filer application go?"
89 get_dir
"/usr/local/apps"
92 echo "Where should the launcher script go?"
93 get_dir
"/usr/local/bin"
96 echo "Where should the manual page go?"
97 get_dir
"/usr/local/man"
100 *) die
"Invalid choice!";;
105 The application directory will be:
108 The launcher script will be:
112 if [ -n "$MANDIR" ]; then
113 echo "The manual pages will be:"
114 echo " $MANDIR/man1/rox.1"
115 echo " $MANDIR/man1/ROX-Filer.1"
117 echo "The manual page will not be installed."
125 if [ -n "$MANDIR" ]; then
126 echo "Installing manpage..."
129 cp rox
.1 "$MANDIR/man1/rox.1" || die
"Can't install manpage!"
130 rm -f "$MANDIR/man1/ROX-Filer.1" || die
"Can't install manpage!"
131 ln -s "$MANDIR/man1/rox.1" "$MANDIR/man1/ROX-Filer.1" || die
"Can't install manpage!"
134 echo "Installing application..."
137 (cd ROX-Filer
/src
; make clean
) > /dev
/null
138 if [ -d "$APPDIR/ROX-Filer" ]; then
139 echo "ROX-Filer is already installed - delete the existing"
143 rm -rf "$APPDIR/ROX-Filer"
145 cp -r ROX-Filer
"$APPDIR"
147 echo "Installing launcher script..."
150 cat > "$BINDIR/rox" << EOF
152 exec $APPDIR/ROX-Filer/AppRun "\$@"
154 [ $?
-eq 0 ] || die
"Failed to install 'rox' script"
155 chmod a
+x
"$BINDIR/rox"
158 Script installed. You can run the filer by simply typing 'rox'
159 Make sure that $BINDIR is in your PATH though - if it isn't then
165 if [ ! -n "$CHOICESPATH" ]; then
166 CHOICESPATH
=${HOME}/Choices
:/usr
/local
/share
/Choices
:/usr
/share
/Choices
172 ROX-Filer requires some icons and other defaults. These should be
173 installed where it can find them. By default, it looks in
174 \${HOME}/Choices (${HOME}/Choices in your case)
175 /usr/local/share/Choices
177 in that order. You can choose a different search path by setting
178 the CHOICESPATH environment variable before running the filer. These
179 files are supplied in the 'rox-base' package. Make sure you have the
180 latest version installed!
185 REPORT
="I couldn't find the required files!"
187 for DIR
in $CHOICESPATH; do
188 if [ ! -n "$DIR" ]; then
192 echo Looking
for files
in $DIR...
194 if [ -f "$DIR/MIME-icons/application_x-executable.png" ]; then
198 elif [ -d "$DIR/MIME-icons" ]; then
199 REPORT
="I found an old installation in $DIR, but not the latest version."
203 if [ -n "$REPORT" ]; then
206 echo "Please download and install the latest version of the rox-base package"
207 echo "from http://rox.sourceforge.net before using the filer!"
216 ****************************
217 *** Now read the manual! ***
218 ****************************
220 Run ROX and click on the information icon on the toolbar: