problem with suppressed output to file using echo and tee command
Hi,
When I run the following command in terminal it works. The string TEST is appended to a file silently.
However, when I paste this same line to a file, say shell1.sh, and use bourne shell .
I run this file in terminal, ./shell1.sh.
However I still get the output TEST in the display. Is this some kind of limitation of bourne shell. How can I suppress this output?
I'm not a complete novice at unix but I'm not all that advanced either. I'm hoping that someone with a little more knowledge than myself has the answer I'm looking for.
I'm writing a wrapper script that will be passed user commands from the cron...
Ex:
./mywrapper.sh "/usr/bin/ps -ef |... (1 Reply)
Hi,
i need to print following text using echo:
/abc dir/c\
so i tried echo "/abc dir/c\
But it gives me error of Incorrect usage, i am using Hamilton cshell in windows Vista. Can any one please help me.
Thanks in advance
Sarbjit (3 Replies)
Hello,
I'm writing some bash scripts and I'm trying to get an echo command and the output of another command to display on the same line. For example:
I want to run
echo "Operating System: " unameand have it displayed as
Operating System: Darwin
Thanks for your help! (7 Replies)
Hi,
I try to write script and echo two command at the same line .
echo "A"
echo "B"
How can I pipe above two command at the same line in text file .
So, in the output text file , you can see below ???
A B
not
A
B
Any sugggestion ??? (4 Replies)
My intention is to log the output to a file as well as it should be displayed on the console > I have used tee ( tee -a ${filename} ) command for this purpose. This is working as expected for first few outputs, after some event loggin nothing is gettting logged in to the file but It is displaying... (3 Replies)
BACK STORY:
I have a script build.py . (It's for creating the ISO file for a special edition of Swift Linux.) This build.py script executes the mintConstructor.py script that I use to modify the Regular Swift Linux ISO to get the special edition Swift Linux ISO. The lines of the script that... (2 Replies)
I am trying to get ascii file using echo command, e.g. -
echo "\050"
It is correctly working on RHEL 4 but not in RHEL 5. Please help me to fix the issue.
## Working as expected in RHEL 4
$ lsb_release -d
Description: Red Hat Enterprise Linux AS release 4 (Nahant Update 8)
$ echo... (4 Replies)
Hello all,
I wrote this command line for some calculation on my given input files based on another input file which is a txt file.
while read BAM REGION; do samtools view $BAM $REGION | awk '{if ($2==0) print $0}' | wc -l >>log.txt; echo "$REGION"; done >> log.txt <regions.txt
It takes... (4 Replies)
Hello
i am trying to do some calculation from output command
for example
ls -l
if
then
echo "error"
else
echo "$"
fi
its something like this
which get strings from output command and try to sum total lines of this string if exceed certain number it display error
if not it... (3 Replies)
How do i echo the output of a unix command using shell script???
Like:
echo /etc/ ls -l (2 Replies)
Discussion started by: sunny2802
2 Replies
LEARN ABOUT OSX
apache::testrun
Apache::TestRun(3) User Contributed Perl Documentation Apache::TestRun(3)NAME
Apache::TestRun - Run the test suite
SYNOPSIS DESCRIPTION
The "Apache::TestRun" package controls the configuration and running of the test suite.
METHODS
Several methods are sub-classable, if the default behavior should be changed.
"bug_report"
The "bug_report()" method is executed when "t/TEST" was executed with the "-bugreport" option, and "make test" (or "t/TEST") fail. Normally
this is callback which you can use to tell the user how to deal with the problem, e.g. suggesting to read some document or email some
details to someone who can take care of it. By default nothing is executed.
The "-bugreport" option is needed so this feature won't become annoying to developers themselves. It's automatically added to the
"run_tests" target in Makefile. So if you repeateadly have to test your code, just don't use "make test" but run "t/TEST" directly. Here is
an example of a custom "t/TEST"
My::TestRun->new->run(@ARGV);
package My::TestRun;
use base 'Apache::TestRun';
sub bug_report {
my $self = shift;
print <<EOI;
+--------------------------------------------------------+
| Please file a bug report: http://perl.apache.org/bugs/ |
+--------------------------------------------------------+
EOI
}
"pre_configure"
The "pre_configure()" method is executed before the configuration for "Apache::Test" is generated. So if you need to adjust the setup
before httpd.conf and other files are autogenerated, this is the right place to do so.
For example if you don't want to inherit a LoadModule directive for mod_apreq.so but to make sure that the local version is used, you can
sub-class "Apache::TestRun" and override this method in t/TEST.PL:
package My::TestRun;
use base 'Apache::TestRun';
use Apache::TestConfig;
__PACKAGE__->new->run(@ARGV);
sub pre_configure {
my $self = shift;
# Don't load an installed mod_apreq
Apache::TestConfig::autoconfig_skip_module_add('mod_apreq.c');
$self->SUPER::pre_configure();
}
Notice that the extension is .c, and not .so.
Don't forget to run the super class' c<pre_configure()> method.
"new_test_config"
META: to be completed
perl v5.16.2 2011-02-07 Apache::TestRun(3)