Sponsored Content
Top Forums Shell Programming and Scripting Issue with spaces in Java command line options Post 302512918 by KenJackson on Monday 11th of April 2011 11:24:03 PM
Old 04-12-2011
Quote:
Originally Posted by Romain
JAVA_OPTS=("-Xms256m -Xmx256m")
That's an array with one element, not two as you might have wanted.

Either of these will give two elements:
JAVA_OPTS=("-Xms256m" "-Xmx256m")
JAVA_OPTS=(-Xms256m -Xmx256m)

That seems like it could give Java heartburn, though it's not my language so I'm not sure.
 

10 More Discussions You Might Find Interesting

1. Programming

Executing command line options

Can someone please tell me how to modify/add to this code so that it recognizes UNIX command options (all beginning with "-") and executes the command with options? #include<stdio.h> #include<stdlib.h> int main(int argc, char *argv) { int i; system("stty -echo"); ... (8 Replies)
Discussion started by: Safia
8 Replies

2. Shell Programming and Scripting

Associated array from command line options

I am looking to populate an (associated) array with a command line argument. The command line would look something like this: alert -action test -priority '10' -module test_module . . . The associated array would look like this after the data is read in flag=(action=test priority=10... (1 Reply)
Discussion started by: jperret
1 Replies

3. Shell Programming and Scripting

how to? launch command with string of command line options

my description from another thread... here's my code: #!/bin/bash IFS=$'\n' function OutputName() { input=$1 echo $input input=`echo "$input" | sed -e 's/.//'` input=`echo "$input".avi` output_name=$input } if ]; then echo... (5 Replies)
Discussion started by: TinCanFury
5 Replies

4. Shell Programming and Scripting

Using perl to get options from command line

Hi all, I want to get options from command line by perl. usage() options: -h Show this help message and exit -t Name of tester --timeout Set the timeout -l ... (1 Reply)
Discussion started by: Damon_Qu
1 Replies

5. Shell Programming and Scripting

Run perl script, with command-line options

Hello everyone, I have a perl script which takes various command line options from user like : test.pl -i <input_file> -o <output_file> -d <value> -c <value> Now I have multiple input files in a directory: <input_file_1> <input_file_2> <input_file_3> <input_file_4> ..... .... ...... (6 Replies)
Discussion started by: ad23
6 Replies

6. Shell Programming and Scripting

awk script file command line options

Being new to awk I have a really basic question. It just has to be in the archives but it didn't bite me when I went looking for it. I've written an awk script, placed it in a file, added the "#!/usr/bin/awk -f" at the top of the script and away I go. "% myAwk <inputfile>" gives me exactly what... (2 Replies)
Discussion started by: tomr2k
2 Replies

7. UNIX for Dummies Questions & Answers

Running set options from the command line and bash command

I'm reading about debugging aids in bash and have come across the set command. It says in my little book that an addition to typing set you can also use them "on the command line when running a script..." and it lists this in a small table: set -o option Command Line... (5 Replies)
Discussion started by: Straitsfan
5 Replies

8. Shell Programming and Scripting

Reading command line options from bash script

I have the following code and I am calling it using ./raytrac.bash -u and getting problems. For some reason opt_usage is still 0. opt_usage=0 iarg=0 narg=$# while (($iarg < $narg)) do (( iarg = $iarg + 1 )) arg=$argv usrInputFlag=`echo $arg | awk '/=/ {print 1}; ! /=/... (22 Replies)
Discussion started by: kristinu
22 Replies

9. Shell Programming and Scripting

Select command with variable options having spaces or null contents

Hi, I'm having an issue trying to produce a hierarchical directory menu that has either any directories listed in a specific directory as options or options with spaces in the option content or null content. So the menu function gets passed a base directory, it then lists any .sh scripts in... (6 Replies)
Discussion started by: andyatit
6 Replies

10. Shell Programming and Scripting

Processing Multiple Arguments in Command Line Options

Hi All, I am new to scripting. Could you please assist me . Here is my requirement. I have written a script that has 2 option flags defined. -l) calls some function with the arguments passed in front of -l -r) calls second function with the arguments passed in front of -r *) calls the... (7 Replies)
Discussion started by: Jay Deshpande
7 Replies
fsc(1)								   USER COMMANDS							    fsc(1)

NAME
fsc - Fast offline compiler for the Scala 2 language SYNOPSIS
fsc [ <options> ] <source files> PARAMETERS
<options> Command line options. See OPTIONS below. <source files> One or more source files to be compiled (such as MyClass.scala). OPTIONS
The offline compiler supports all options of scalac plus the following: -reset Reset compile server caches. -shutdown Shut down the compilation daemon. The daemon attempts to restart itself as necessary, but sometimes an explicit shutdown is required. A common example is if jars on the class path have changed. -server <hostname:portnumber> Specify compile server host at port number. Usually this option is not needed. Note that the hostname must be for a host that shares the same filesystem. -J <flag> Pass <flag> directly to the Java VM for the compilation daemon. DESCRIPTION
The fsc tool submits Scala compilation jobs to a compilation daemon. The first time it is executed, the daemon is started automatically. On subsequent runs, the same daemon can be reused, thus resulting in a faster compilation. The tool is especially effective when repeatedly compiling with the same class paths, because the compilation daemon can reuse a compiler instance. The compilation daemon is smart enough to flush its cached compiler when the class path changes. However, if the contents of the class path change, for example due to upgrading a library, then the daemon should be explicitly shut down with -shutdown. Note that the scala script runner will also use the offline compiler by default, with the same advantages and caveats. EXAMPLE
The following session shows a typical speed up due to using the offline compiler. > fsc -verbose -d /tmp test.scala ... [Port number: 32834] [Starting new Scala compile server instance] [Classpath = ...] [loaded directory path ... in 692ms] ... [parsing test.scala] ... [total in 943ms] > fsc -verbose -d /tmp test.scala ... [Port number: 32834] [parsing test.scala] ... [total in 60ms] > fsc -verbose -d /tmp test.scala ... [Port number: 32834] [parsing test.scala] ... [total in 42ms] > fsc -verbose -shutdown [Scala compile server exited] ENVIRONMENT
JAVACMD Specify the java command to be used for running the Scala code. Arguments may be specified as part of the environment variable; spaces, quotation marks, etc., will be passed directly to the shell for expansion. JAVA_HOME Specify JDK/JRE home directory. This directory is used to locate the java command unless JAVACMD variable set. JAVA_OPTS Specify the options to be passed to the java command defined by JAVACMD. With Java 1.5 (or newer) one may for example configure the memory usage of the JVM as follows: JAVA_OPTS="-Xmx512M -Xms16M -Xss16M" With GNU Java one may configure the memory usage of the GIJ as follows: JAVA_OPTS="--mx512m --ms16m" EXIT STATUS
fsc returns a zero exit status if it succeeds to compile the specified input files. Non zero is returned in case of failure. AUTHOR
Written by Martin Odersky and other members of the Scala team. REPORTING BUGS
Report bugs to http://lampsvn.epfl.ch/trac/scala. COPYRIGHT
This is open-source software, available to you under a BSD-like license. See accomponying "copyright" or "LICENSE" file for copying condi- tions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. SEE ALSO
sbaz(1), scala(1), scalac(1), scaladoc(1), scalap(1) version 0.4 January 18, 2007 fsc(1)
All times are GMT -4. The time now is 07:44 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy