02-13-2012
Because the shell only substitutes once. after it's done substituting in the text from the string, it won't go back and see that it was actually meant as a redirection. To do that kind of double-think, you'd have to feed it into eval.
This User Gave Thanks to Corona688 For This Post:
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
First of all, hello there cOmMuNity ! :cool:
Well, I've got two basic questions:
1) In how many ways it's possible to create a file ?
I know one manner using "touch", other typing something like echo "" > file ...
The fact is that I need to overwrite the file if it exists, and touch... (8 Replies)
Discussion started by: 435 Gavea
8 Replies
2. UNIX for Advanced & Expert Users
when i write the following two statements :
cp /dev/NULL /clocal/mqbrkrs/user/mqsiadm/sanjay/dspmq_temp
cat /dev/NULL > /clocal/mqbrkrs/user/mqsiadm/sanjay/dspmq_temp
its gives me errors like :
cp: /dev/NULL: A file or directory in the path name does not exist.
cat : /dev/NULL can't open... (2 Replies)
Discussion started by: varungupta
2 Replies
3. Solaris
Hi, Anyone can help
My solaris 8 system has the following
/dev/null , /dev/tty and /dev/console
All permission are lrwxrwxrwx
Can this be change to a non-world write ??
any impact ?? (12 Replies)
Discussion started by: civic2005
12 Replies
4. Shell Programming and Scripting
Hi,
I am new into UNIX shell scripting and I am wondering what is the meaning of the below text which appears at the end of each line in the ".sh" file:
> /dev/null 2>&1
For example, the line below:
sh $HOME/stats/Rep777/Act_777.sh omc omc > /dev/null 2>&1
I know for sure what "sh... (10 Replies)
Discussion started by: salanalani
10 Replies
5. Shell Programming and Scripting
Does >/dev/null 2>&1 and 2>&1 >/dev/null mean the same? (4 Replies)
Discussion started by: proactiveaditya
4 Replies
6. UNIX for Dummies Questions & Answers
How are these two different? They both prevent output and error from being displayed. I don't see the use of the "&"
echo "hello" > /dev/null 2>&1
echo "hello" > /dev/null 2>1 (3 Replies)
Discussion started by: glev2005
3 Replies
7. Shell Programming and Scripting
why is this giving me errors?
i type this in: find / -name "something.txt" 2>/dev/null
i get the following error messages:
find: bad option 2
find: path-list predicate-list
:confused: (5 Replies)
Discussion started by: magiling
5 Replies
8. UNIX for Dummies Questions & Answers
Hi,
I'm currently using the following command to wipe clean a log file which can't be straight out RM'd:
cat /dev/null > server.log
I'm building this into a script and I'm current working on a command to run on each machine to do this automatically however I have multiple files so I need... (11 Replies)
Discussion started by: Deehem
11 Replies
9. UNIX for Dummies Questions & Answers
Hello.
When I run a .ksh that contains the command below, and there is no file available in the source location the "FILE_NAME_*.CSV not found" error is still being displayed.
FILEN=$(ssh ${SOURCE_SERV} "cd ${SOURCE_LOCATION} ;ls ${FILES}") 2> /dev/null.
This is interfering with the rest... (4 Replies)
Discussion started by: jimbojames
4 Replies
10. AIX
Hi Experts,
I Have a query. In one of my server I just came to know that there was /dev/null file which is a not a character file. Its just a normal file. I know the command to create the character file (/dev/null) but what is the procedure. Like should i delete /dev/null and create or... (7 Replies)
Discussion started by: jayadeava
7 Replies
J0(3) BSD Library Functions Manual J0(3)
NAME
j0, j1, jn, y0, y1, yn -- bessel functions of first and second kind
SYNOPSIS
#include <math.h>
double
j0(double x);
double
j1(double x);
double
jn(int n, double x);
double
y0(double x);
double
y1(double x);
double
yn(int n, double x);
DESCRIPTION
The functions j0(x) and j1(x) compute the Bessel function of the first kind of the order 0 and the order 1, respectively; the function jn(n,
x) computes the Bessel function of the first kind of the integer order n.
The functions y0(x) and y1(x) compute the linearly independent Bessel function of the second kind of the order 0 and the order 1, respec-
tively, for the positive integer value x (expressed as a double); the function yn(n, x) computes the Bessel function of the second kind for
the integer order n for the positive integer value x (expressed as a double).
SPECIAL VALUES
j0(0) returns 1.
j0(+-infinity) returns 0.
j0(NaN) returns a NaN.
j1(0) returns 0.
j1(+infinity) returns 0.
j1(NaN) returns a NaN.
y0(0) , y1(0) , and yn(n, 0) all return -infinity and raise the "division-by-zero" floating-point flag.
4th Berkeley Distribution December 11, 2006 4th Berkeley Distribution