03-03-2010
Thanks for attention . Doesn't work the file even doesn't get created..
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
i use awk -F to print three variable delimited by comma $1 $2 $3
if $2=="" i want to extract this information missing from another file using awk -v + some process.
but the problem i can't use the two awk together cause of redirection
there's a solution.
note: i can't use another... (1 Reply)
Discussion started by: kamel.seg
1 Replies
2. UNIX for Dummies Questions & Answers
Apologies for the trivial nature of this question but I cannot seem to get a simple re direct to a log file to work
Step 1
touch log.txt
at -f batch.sh now >> log.txt
I am trying to get the batch.sh contents into the log file
Manny Thanks (8 Replies)
Discussion started by: JohnCrump
8 Replies
3. Shell Programming and Scripting
Hi,
I want ssh to the remote server and then execute ls and redirect the output to the file in remote server itself
like
ssh root@$server `ls /var/log/users.txt > root@$server:/home/users.txt`
Can you please let me know the correct syntax for it.
Thanks in advance (2 Replies)
Discussion started by: mohitmoudgil
2 Replies
4. UNIX for Dummies Questions & Answers
Suppose I have a file named a
When I write
cat a>a
The following error message is displayed
cat: a: input file is output file
and my file a is truncated to zero size.
Also the exit status of the last command is 1
Can someone tell me what actually happens when I do so? (1 Reply)
Discussion started by: aagajaba
1 Replies
5. UNIX for Dummies Questions & Answers
I am trying to write a script which will output notifications to a logfile, but I would like to cap the logfile to, let's say, 200 lines.
Specifically I am using custom firmware, DD-wrt, on my router and I am implementing a script to connect to my work vpn. I have a loop that pings a computer... (2 Replies)
Discussion started by: joemommasfat
2 Replies
6. Shell Programming and Scripting
So I have a existing file that I used the uniq command on and I need to save the output to the same file without changing the file name.
I have tried $ uniq filename > filename
then when I cat the file it then becomes blank like there is nothing inside.
any help would be much appreciated... (0 Replies)
Discussion started by: drew211
0 Replies
7. Shell Programming and Scripting
I am struck up with a problem and that is with output redirection.
I used all the ways for the redirection of the output of c binary to a file, still it is failing.
Here are the different ways which I have used:
./a.out | tee -a /root/tmp.txt 2>&1
./a.out | tee -a /root/tmp.txt 1>&1
./a.out |... (2 Replies)
Discussion started by: Maya29988
2 Replies
8. UNIX for Dummies Questions & Answers
I almost reach my objective (Youhouuu !!!!)
But I really don't understand why it doesn't work until the end... :wall:
For clarity's sake I am taking a very simple example. The operations I am doing in the script (gsub and print) really don't have any importance !!! I just matter about... (10 Replies)
Discussion started by: beca123456
10 Replies
9. Shell Programming and Scripting
Hi,
I have a peculiar issue w.r.t redirecting the command output to a file when using loop.
I am redirecting command output to same file in a series of if condition statements, but if one block of if condition statement writes the log to the file , the subsequent block of if condition... (7 Replies)
Discussion started by: ananan
7 Replies
10. Shell Programming and Scripting
So I'm writing a script which tries to parse human-readable addresses. Part of it is this:
print $2, implode(A,1,AN," "), CITY, PROV, POST, COUNTRY, CITYCOUNT>2;
CITYCOUNT is a variable between 0 and 3 counting the number of words in a city name. I'm trying to prnt 1 wherever that's greater... (5 Replies)
Discussion started by: Corona688
5 Replies
H2PH(1) Perl Programmers Reference Guide H2PH(1)
NAME
h2ph - convert .h C header files to .ph Perl header files
SYNOPSIS
h2ph [-d destination directory] [-r | -a] [-l] [headerfiles]
DESCRIPTION
h2ph converts any C header files specified to the corresponding Perl header file format. It is most easily run while in /usr/include:
cd /usr/include; h2ph * sys/*
or
cd /usr/include; h2ph * sys/* arpa/* netinet/*
or
cd /usr/include; h2ph -r -l .
The output files are placed in the hierarchy rooted at Perl's architecture dependent library directory. You can specify a different hier-
archy with a -d switch.
If run with no arguments, filters standard input to standard output.
OPTIONS
-d destination_dir
Put the resulting .ph files beneath destination_dir, instead of beneath the default Perl library location ($Config{'installsit-
search'}).
-r Run recursively; if any of headerfiles are directories, then run h2ph on all files in those directories (and their subdirectories,
etc.). -r and -a are mutually exclusive.
-a Run automagically; convert headerfiles, as well as any .h files which they include. This option will search for .h files in all direc-
tories which your C compiler ordinarily uses. -a and -r are mutually exclusive.
-l Symbolic links will be replicated in the destination directory. If -l is not specified, then links are skipped over.
-h Put ``hints'' in the .ph files which will help in locating problems with h2ph. In those cases when you require a .ph file containing
syntax errors, instead of the cryptic
[ some error condition ] at (eval mmm) line nnn
you will see the slightly more helpful
[ some error condition ] at filename.ph line nnn
However, the .ph files almost double in size when built using -h.
-D Include the code from the .h file as a comment in the .ph file. This is primarily used for debugging h2ph.
-Q ``Quiet'' mode; don't print out the names of the files being converted.
ENVIRONMENT
No environment variables are used.
FILES
/usr/include/*.h
/usr/include/sys/*.h
etc.
AUTHOR
Larry Wall
SEE ALSO
perl(1)
DIAGNOSTICS
The usual warnings if it can't read or write the files involved.
BUGS
Doesn't construct the %sizeof array for you.
It doesn't handle all C constructs, but it does attempt to isolate definitions inside evals so that you can get at the definitions that it
can translate.
It's only intended as a rough tool. You may need to dicker with the files produced.
You have to run this program by hand; it's not run as part of the Perl installation.
Doesn't handle complicated expressions built piecemeal, a la:
enum {
FIRST_VALUE,
SECOND_VALUE,
#ifdef ABC
THIRD_VALUE
#endif
};
Doesn't necessarily locate all of your C compiler's internally-defined symbols.
perl v5.8.0 2003-02-18 H2PH(1)