Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Redirect output of echo to a file Post 302842565 by MadeInGermany on Friday 9th of August 2013 12:53:54 PM
Old 08-09-2013
Quote:
Originally Posted by ASC
Can anyone tell me why the printline function i wrote is logging everything correctly except the last echo statement in the script ?
It works for me (in bash, and after removing the word function in sh and ksh).
Someone mentioned the printline versus printLine in your post, but that gives "not found" errors, and does not explain the bug that you encounter.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

redirect output to file?

Hi: I am currently working on a program which requires direct its ouput to a file here is an example ./proram arg_1 arg_2 when program ends all output will be arg_2 file Is that possible I am not a bad programmer, However I am stuck there. Can anyone give a hint? Thanks SW (1 Reply)
Discussion started by: slackware
1 Replies

2. UNIX for Dummies Questions & Answers

Redirect output to a file

Ahhhrrrggg I'm having a brain fart... I want to take the output of a command and redirect it to a file... This works.... $ man cp | cat >> copy_help but this doesn't keytool -help |cat >> keytool_help It just produces... these lines... more keytool_help ] ... ... (11 Replies)
Discussion started by: jimmyc
11 Replies

3. UNIX for Dummies Questions & Answers

redirect output to a file name

Hi all!! is possible to assign the output of some command to filename, i.e. grep_output.txt Otherwise, I want to open a new file which name is inside another, how can I do it? Thanks a lot! (7 Replies)
Discussion started by: csecnarf
7 Replies

4. UNIX for Dummies Questions & Answers

redirect output into the middle of a file

If I want to cat one file and have the output inserted into a specific place on another file, how is this done? I know how to append >> and to overwrite > but say I have a file with: File1: abc def ghi jkl And a File with: File2: mno pqr stu vwx And I want to place the... (5 Replies)
Discussion started by: glev2005
5 Replies

5. Shell Programming and Scripting

How redirect standard output to a file

Hi guys, i have a script named purgeErrors.ksh, when i execute this script i need to redirect the output to a log file in the same directory, how can i do that ?? -- Aditya (5 Replies)
Discussion started by: chaditya
5 Replies

6. Shell Programming and Scripting

How to redirect output of ls to a file?

Hi All, I want to redirect only the file names to a new file from the ls -ltr directroy. how Can i do it. my ls -ltr output will be as below. -rwxr-xr-x 1 118 103 28295 Jul 26 2006 event.podl -rwxr-xr-x 1 118 103 28295 Jul 26 2006 xyz.podl I want my new file... (6 Replies)
Discussion started by: girish.raos
6 Replies

7. UNIX for Advanced & Expert Users

Redirect Topas output to a file

Hi, I want to know how to redirect the output of topas -P to a file in a readable format. I tried doing it by using topas -P > topas.txt but the output is not properly aligned and when I opened it using vi it ahd some characters. Please help me out in this. Thanks (1 Reply)
Discussion started by: Preetha
1 Replies

8. Shell Programming and Scripting

script to mail monitoring output if required or redirect output to log file

Below script perfectly works, giving below mail output. BUT, I want to make the script mail only if there are any D-Defined/T-Transition/B-Broken State WPARs and also to copy the output generated during monitoring to a temporary log file, which gets cleaned up every week. Need suggestions. ... (4 Replies)
Discussion started by: aix_admin_007
4 Replies

9. Shell Programming and Scripting

Redirect script output to a file and mail the output

Hi Guys, I want to redirect the output of 3 scripts to a file and then mail the output of those three scripts. I used below but it is not working: OFILE=/home/home1/report1 echo "report1 details" > $OFILE =/home/home1/1.sh > $OFILE echo... (7 Replies)
Discussion started by: Vivekit82
7 Replies

10. Shell Programming and Scripting

Echo cannot redirect first or second output to logfile

I created a script to do some work. I want to use "echo" to redirect "date" to log file. echo works to screen. But cannot redirect first or second "echo" output to logfile. Please help. My code looks like: STARTTIME=`date +%m-%d-%Y` LOGFILE=/directory/logfile.log echo "Start time:" $STARTTIME... (8 Replies)
Discussion started by: duke0001
8 Replies
NXDIR(1)						      General Commands Manual							  NXDIR(1)

NAME
nxdir - inspect a NeXus file non interactively SYNOPSIS
nxdir filename [options] DESCRIPTION
nxdir allows to retrieve the structure and/or data of a NeXus file. OPTIONS
About NXdir -h|--help Print help information and exit. --version Print version information and exit. Node Selection -p path Path inside the file to look in. This can be absolute or relative and can be class or name of a given field. To anchor the path at the beginning or end place a "/" there. To specify that a level must exist, but the name or class can be anything, use a dot ".". To specify that any number of levels can exist, use a star "*". Output Control -o/+o Print (or not) the value of selected nodes, if possible. Defaults to false (+o). -l|--max-array Change the number of elements that are printed for arrays. Forces "-o". (default: 10) -t|--tree-mode value Sets the formatting of the tree. Allowed values are: script, multi, tree. Default is script. --path-mode value Select whether paths are written with names or classes. Allowed values are: name, class, both. Default is name. --data-mode value How data is printed. Allowed value is script --printline value How data is printed with respect to tree. Allowed values is single --write-data filename Select a file to write out selected NXdata to. --dump filename Generate a binary dump of the selected node. SEE ALSO
nxbrowse(1) http://www.nexusformat.org AUTHOR
nxdir was originally written by P. F. Peterson <petersonpf@ornl.gov> This manual page was written by Tobias Richter <Tobias.Richter@diamond.ac.uk> and may be used by others. June 2010 NXDIR(1)
All times are GMT -4. The time now is 01:25 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy