Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Declaring variable environments in .cshrc Post 28746 by LivinFree on Monday 23rd of September 2002 10:25:45 PM
Old 09-23-2002
Quick correction:
Bourne related shells (sh, bash, ksh, etc...) cannot have a space in the assignment.
For example,
CLASSPATH = .:/myclasses
should be:
CLASSPATH=.:/myclasses
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Declaring Local Arrays

I have some function function() { fileNamelist=( `find Uploads -name "somePattern" | tr '\n' ' '` ) } but "local fileNamelist" makes it variable. How do I declare fileNameList as a local array in BASH? (1 Reply)
Discussion started by: ksh
1 Replies

2. Shell Programming and Scripting

Declaring functions in CSH

Hi all, It might seem like a very trivial question but I am new to shell scripting so excuse for that. I have an existing script in CSH. I need to create a function in the script which takes some parameters and returns a result. Can someone please let me know the syntax for function... (4 Replies)
Discussion started by: tipsy
4 Replies

3. BSD

Declaring Global Variables in KLD

Hello, how can I define a global variables in KLD? I would like to define some variables in my KLD and then would like to use them from other KLD. Thanx (1 Reply)
Discussion started by: int80h
1 Replies

4. UNIX for Dummies Questions & Answers

cshrc Environment Variable Question

How do I input the environment variable in the .cshrc file to have the up and down arrows recall the last commands??? This is for Solaris 10. :confused::confused: (1 Reply)
Discussion started by: CFSR
1 Replies

5. Shell Programming and Scripting

declaring variable with for $(seq)

Hi guys. i have the following script: 1 #!/bin/bash 2 linkcount=$(grep "/portal" tickets | wc -l) 3 grep "/portal" tickets > links 4 for i in $(seq 1 $linkcount); do 5 echo "BLYAT" 6 let link$i=$(sed -n "$i"p links) 7 echo $ 8 done the problem is, that "let" can`t... (1 Reply)
Discussion started by: neverhood
1 Replies

6. Programming

Declaring variables

Hey guys im facing a problem in declaring variables. i have a few classes like the one below... #ifndef _FINANCE_H #define _FINANCE_H #include <string> #include <iostream> #include <fstream> #include <stdlib.h> using namespace std ; class readStraitsTimesIndex { ... (3 Replies)
Discussion started by: gregarion
3 Replies

7. Shell Programming and Scripting

Declaring variable with another variable

Hi All, The issue is that for changing name of the file i'm writing a script, there the at one point i need to declare a variable some thing like 'var1, var2, var3 ......' which has to store some value. Script as follows: for i in `echo xxxx_dddd_ccc_plsql_zz.sql |tr "_" ' '` do ... (2 Replies)
Discussion started by: girish_satyam
2 Replies

8. Shell Programming and Scripting

Declaring variables without initialization

I get an error in my shell script that line 1: )unexpected. Line 1 in my script (using sh by the way) is the variable I declared but did not initialize it. result= Is this wrong? How can I fix it? I am using the variable later in the program, so I figured I could just declare it first... (4 Replies)
Discussion started by: itech4814
4 Replies

9. UNIX for Dummies Questions & Answers

PERL: Declaring Array

Is it possible to declare an array in the following way: @tmp = (@f,"String1","String2", "String3",@f); I'm getting the following error message: Array found where operator expected at Program.pl line 181, near "" (Missing semicolon on previous line?) ---------- Post updated at... (1 Reply)
Discussion started by: WongSifu
1 Replies

10. Shell Programming and Scripting

Declaring arrays in csh

Does anyone know how to declare an array in csh? I don't want to declare any elements in the array because I have a variable that represents the size of the array. For example: the array I want to declare is called sortList and it passes in the variable ARRAYSIZE that stores the value 8. (1 Reply)
Discussion started by: demet8
1 Replies
java_home(1)						      General Commands Manual						      java_home(1)

NAME
java_home - return a value for $JAVA_HOME SYNOPSIS
/usr/libexec/java_home [options] DESCRIPTION
The java_home command returns a path suitable for setting the JAVA_HOME environment variable. It determines this path from the user's enabled and preferred JVMs in the Java Preferences application. Additional constraints may be provided to filter the list of JVMs avail- able. By default, if no constraints match the available list of JVMs, the default order is used. The path is printed to standard output. OPTIONS
-v or --version version Filters the returned JVMs by the major platform version in "JVMVersion" form. Example versions: "1.5+", or "1.6*". -a or --arch architecture Filters the returned JVMs by the architecture they support. Example architectures: "i386", "x86_64", or "ppc". -d or --datamodel datamodel Filters the returned JVMs capable of running in 32 or 64-bit mode. Supported datamodels: "-d32" and "-d64". Specifying a datamodel is synonymous with specifying a particular architecture. -t or --task task Selects from the list of JVMs which can run a specific task. The order of each of these lists is set by the Java Preferences appli- cation. Supported tasks: "Applets", "WebStart", "BundledApp", "JNI" and "CommandLine". The default task is "CommandLine". -F or --failfast Immediately fails when filters return no JVMs; does not print out the path to the default $JAVA_HOME. --exec command ... Executes the command at $JAVA_HOME/bin/<command> and passes the remaining arguments. Any arguments to select which $JAVA_HOME to use must precede the --exec option. -X or --xml Prints the list of selected JVMs and associated properties as an XML plist to stdout. -V or --verbose Prints the matching list of JVMs and architectures to stderr. -h or --help Brief usage information. USAGE
/usr/libexec/java_home helps users set a $JAVA_HOME in their login rc files, or provides a way for command-line Java tools to use the most appropriate JVM which can satisfy a minimum version or architecture requirement. The --exec argument can invoke tools in the selected $JAVA_HOME/bin directory, which is useful for starting Java command-line tools from launchd plists without hardcoding the full path to the Java command-line tool. Usage for bash-style shells: $ export JAVA_HOME=`/usr/libexec/java_home` Usage for csh-style shells: % setenv JAVA_HOME `/usr/libexec/java_home` 04 August 2010 java_home(1)
All times are GMT -4. The time now is 11:03 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy