Sponsored Content
Full Discussion: Looping through input/output
Top Forums UNIX for Beginners Questions & Answers Looping through input/output Post 302979965 by zajtat on Monday 22nd of August 2016 12:23:38 PM
Old 08-22-2016
Thank you all for your comments and suggestions. I do understand that the solution to any problem is proper communication and my point was that since we are communicating in writing only, even with best intentions and the biggest trust in the world, it is easy to get misunderstood or be misunderstood (both ways, not one way only). In any case, I apologise once again for not being able to provide an explanation that would be understandable to everyone or share every script. I do understand that it prevents people in this forum from helping me and have solved the problem in other way. Many thanks everyone for your time and help!

Last edited by zajtat; 08-22-2016 at 07:09 PM..
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Using Output from one command as input to another

This site has been very helpful thus far.. I thank you all in advance for sharing the knowledge. Let me get to it. I am trying to write a very small script to take away from the boredom of doing the same thing over and over. Everynow and again I have to get the hex value of a file using a... (2 Replies)
Discussion started by: BkontheShell718
2 Replies

2. UNIX for Advanced & Expert Users

input/Output settings

How can we view all the input/output settings of unix environment for a session (6 Replies)
Discussion started by: paritoshc
6 Replies

3. Shell Programming and Scripting

input -output file

Hi, I am having an Input file .which is having a list of names. comapring with our database , needs to write the out put in file called output.txt , format should be name--> country--->phone number could you please help me.. thanks in advance (7 Replies)
Discussion started by: hegdeshashi
7 Replies

4. Shell Programming and Scripting

perl: looping through the output of a 'system' command

Hi there could anybody point me in the right direction when it comes to looping through the output of a system command in perl (i.e. df -k) doing a test against each line to see if it matches? for example if i have a df -k output like this and I wanted to grab the lines that matched "sda" or... (3 Replies)
Discussion started by: rethink
3 Replies

5. Shell Programming and Scripting

Dynamic output file generation using a input text file with predefined output format

Hi, I have two files , one file with data file with attributes that need to be sent to another file to generate a predefined format. Example: File.txt AP|{SSHA}VEEg42CNCghUnGhCVg== APVG3|{SSHA}XK|"password" AP3|{SSHA}XK|"This is test" .... etc --------- test.sh has... (1 Reply)
Discussion started by: hudson03051nh
1 Replies

6. Solaris

SVM Solaris 8 Problem. Metastat output looping

Hi friends, I'm newbie to SVM. Just wanna try installed it on one of our server (to do mirroring for disk0 and disk1) but i think im lost until now. :( the steps i've taken is as below:- 1.prtvtoc /dev/rdsk/c1t0d0s2 | fmthard -s - /dev/rdsk/c1t1d0s2 2.metadb -a -c 3 -f c1t0d0s7... (3 Replies)
Discussion started by: kronenose
3 Replies

7. Shell Programming and Scripting

Looping through for user input

Legends, I want to remain in the script until user passes the correct name. I had tried the below code; but it didn't work out. Please help echo "\nPlease enter the source system: \c" while read SYSTEM_NAME do if ]; then echo "\nMaking $SYSTEM_NAME as source system for particular... (5 Replies)
Discussion started by: sdosanjh
5 Replies

8. Shell Programming and Scripting

looping and saving output of each line separately

I have been trying this program for a long time. I am trying to read a file named "odon" line by line; read the first line, send it to do a command saved in a file "perm", once the first line has finished going through the content of the file perm, the result is saved with the number of the line.... (17 Replies)
Discussion started by: iconig
17 Replies

9. UNIX for Dummies Questions & Answers

Looping through the contents of array for output name

Hi all, I am trying to loop through the string contents of an array, to add it during the saving of the output files. I am trying this code to print each column and save it to unique file name, but it doesn't work. Thanks for any help. fnam=(japan usa uk) alldata.dat contained sample data... (1 Reply)
Discussion started by: ida1215
1 Replies

10. Shell Programming and Scripting

Looping over output of 'ls'

Hi, I have some output from 'ls' command and I want to loop over the output in a bash script. What would be a good way to go about it? For example, if the output of the ls command gives me 'prefix1 prefix2 prefix3', how can I set a loop that will iterate over these? many thanks! (5 Replies)
Discussion started by: pc2001
5 Replies
Perl::Critic::Policy::RegularExpressions::ProhibitEscapeUseraContributedPerl::Critic::Policy::RegularExpressions::ProhibitEscapedMetacharacters(3)

NAME
Perl::Critic::Policy::RegularExpressions::ProhibitEscapedMetacharacters - Use character classes for literal meta-characters instead of escapes. AFFILIATION
This Policy is part of the core Perl::Critic distribution. DESCRIPTION
Ever heard of leaning toothpick syndrome? That comes from writing regular expressions that match on characters that are significant in regular expressions. For example, the expression to match four forward slashes looks like: m//////; Well, this policy doesn't solve that problem (write it as "m{////}" instead!) but solves a related one. As seen above, the escapes make the expression hard to parse visually. One solution is to use character classes. You see, inside of character classes, the only characters that are special are "", "]", "^" and "-", so you don't need to escape the others. So instead of the following loose IPv4 address matcher: m/ d+ . d+ . d+ . d+ /x; You could write: m/ d+ [.] d+ [.] d+ [.] d+ /x; which is certainly more readable, if less recognizable prior the publication of Perl Best Practices. (Of course, you should really use Regexp::Common::net to match IPv4 addresses!) Specifically, this policy forbids backslashes immediately prior to the following characters: { } ( ) . * + ? | # We make special exception for "$" because "/[$]/" turns into "/[5.008006/" for Perl 5.8.6. We also make an exception for "^" because it has special meaning (negation) in a character class. Finally, "[" and "]" are exempt, of course, because they are awkward to represent in character classes. Note that this policy does not forbid unnecessary escaping. So go ahead and (pointlessly) escape "!" characters. CONFIGURATION
This Policy is not configurable except for the standard options. BUGS
Perl treats "m/[#]/x" in unexpected ways. I think it's a bug in Perl itself, but am not 100% sure that I have not simply misunderstood... This part makes sense: "#f" =~ m/[#]f/x; # match "#f" =~ m/[#]a/x; # no match This doesn't: $qr = qr/f/; "#f" =~ m/[#]$qr/x; # no match Neither does this: print qr/[#]$qr/x; # yields '(?x-ism:[#]$qr )' CREDITS
Initial development of this policy was supported by a grant from the Perl Foundation. AUTHOR
Chris Dolan <cdolan@cpan.org> COPYRIGHT
Copyright (c) 2007-2011 Chris Dolan. Many rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of this license can be found in the LICENSE file included with this module perl v5.16.3 2014Perl::Critic::Policy::RegularExpressions::ProhibitEscapedMetacharacters(3)
All times are GMT -4. The time now is 03:45 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy