03-31-2006
Try:
eval export SOURCEDIR=\$${ARCHIVE_Interface_Name}SourceDir
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
I want to set a variable in ksh shell (prompt) and echo the value.
$ set x=5
$echo $x
But it is returning null. Can any one please help.
Thanks in advance (1 Reply)
Discussion started by: ammu
1 Replies
2. Shell Programming and Scripting
I have a variable called PATH that contains a path
example: /Users/rtipton/Desktop/testusers/test
I need a sed command to set a variable called USER to the last directory name in that path
PATH="/Users/rtipton/Desktop/testusers/test"
and from that PATH i need USER to = test
I know sed... (4 Replies)
Discussion started by: tret
4 Replies
3. Shell Programming and Scripting
I'm writing a script (C shell) to search for a pattern in file. For example
scriptname pattern file1 file2 filenN
I use for loop to loop through arguments argv, and it does the job if all arguments are supplied. However if only one argument is supplied (in that case pattern ) it should ask to... (5 Replies)
Discussion started by: patryk44
5 Replies
4. Shell Programming and Scripting
I have a shell script I want to run that will set environment variables based on the value of an input variable submitted when the shell script is called. For example:
$ mgenv.sh prod
This would set environment variables for prod
$ mgenv.sh test
This would set environment variables... (1 Reply)
Discussion started by: brtaylor73
1 Replies
5. Shell Programming and Scripting
I'm hoping you guys can help me out here. I've been trying different methods to try and get what IW as hoping would be a fairly simple script but has turned into a pain.
Bit of background - I am writing a script to check values in certain failes to ensure they are corerct. I'm runnign this on... (2 Replies)
Discussion started by: stuc
2 Replies
6. Shell Programming and Scripting
I have a txt file from which i am assiging a value to a variable
using the code in script1
script1.sh
export f=$(sed -n "/Freq *=/ s/.*= *//p" ${R_path}/output.txt)
echo "$f" --------> this works
in script2 ( which executes the script1)
eval ./script1.sh
if && ; then
echo... (1 Reply)
Discussion started by: shashi792
1 Replies
7. HP-UX
Hi,
I am using hp unix
i want to know the use of the following commands
set --
set - variable
thanks (4 Replies)
Discussion started by: gomathi
4 Replies
8. Shell Programming and Scripting
shell script has a command inside back quotes in method update_TABLE
I need to store the count of number of Rows updated and store it in shell script variable "num"
num = 0;
Update_TABLE
Update_TABLE()
{
`echo " set verify off feedback off echo off pagesize 0 head off... (4 Replies)
Discussion started by: finder255
4 Replies
9. Shell Programming and Scripting
Hi,
Will following set up work in bash script? I've got errors if assigning following binary command to a variable. But on the other hand, COMMAND="ls" works. Any explanation please? How can I assign binary command to a variable COMMAND then I can just call ${COMMAND}?
COMMAND="rsync"... (3 Replies)
Discussion started by: hce
3 Replies
10. Shell Programming and Scripting
Hello,
Please see the script found in my computer below. (Ubuntu 14.04)
#!/bin/sh
export APP_DIR="/home/appname"
monitorscript="$APP_DIR""/monitor.sh"
ps cax | grep monitor.sh > /dev/null
if ; then
echo "monitor.sh is running"
else
"$monitorscript"
fi
My question is regarding EXPORT... (3 Replies)
Discussion started by: baris35
3 Replies
LEARN ABOUT DEBIAN
ppi::statement::variable
PPI::Statement::Variable(3pm) User Contributed Perl Documentation PPI::Statement::Variable(3pm)
NAME
PPI::Statement::Variable - Variable declaration statements
SYNOPSIS
# All of the following are variable declarations
my $foo = 1;
my ($foo, $bar) = (1, 2);
our $foo = 1;
local $foo;
local $foo = 1;
LABEL: my $foo = 1;
INHERITANCE
PPI::Statement::Variable
isa PPI::Statement::Expression
isa PPI::Statement
isa PPI::Node
isa PPI::Element
DESCRIPTION
The main intent of the "PPI::Statement::Variable" class is to describe simple statements that explicitly declare new local or global
variables.
Note that this does not make it exclusively the only place where variables are defined, and later on you should expect that the "variables"
method will migrate deeper down the tree to either PPI::Statement or PPI::Node to recognise this fact, but for now it stays here.
METHODS
type
The "type" method checks and returns the declaration type of the statement, which will be one of 'my', 'local', 'our', or 'state'.
Returns a string of the type, or "undef" if the type cannot be detected (which is probably a bug).
variables
As for several other PDOM Element types that can declare variables, the "variables" method returns a list of the canonical forms of the
variables defined by the statement.
Returns a list of the canonical string forms of variables, or the null list if it is unable to find any variables.
symbols
Returns a list of the variables defined by the statement, as PPI::Token::Symbols.
TO DO
- Write unit tests for this
SUPPORT
See the support section in the main module.
AUTHOR
Adam Kennedy <adamk@cpan.org>
COPYRIGHT
Copyright 2001 - 2011 Adam Kennedy.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.
perl v5.10.1 2011-02-26 PPI::Statement::Variable(3pm)