11-07-2019
Hi. Welcome.
What operating system exactly and what shell are you using?
What code have you written so far to attempt to solve this?
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
My requisite is to search for the string "0108"(which is the year and has come in the wrong year format) in a particular column say 4th column in a tab delimited file and then replace it with 2008(the correct year format) in the same position where 0108 was found..The issue is the last... (15 Replies)
Discussion started by: ganesh_248
15 Replies
2. UNIX for Dummies Questions & Answers
Hi All,
My requisite is to search for the string "0108"(which is the year and has come in the wrong year format) in a particular column say 4th column in a tab delimited file and then replace it with 2008(the correct year format) in the same position where 0108 was found in the same file..The... (27 Replies)
Discussion started by: ganesh_248
27 Replies
3. Shell Programming and Scripting
Hello: I have another question. Please consider the following two sample, tab-delimited files:
File_1:
Abf1 YKL112w
Abf1 YAL054c
Abf1 YGL234w
Ace2 YKL150w
Ace2 YNL328c
Cup9 YDR441c
Cup9 YDR442w
Cup9 YEL040w
...
File 2:
...
ABF1 YKL112W
ACE2 YLR131C (9 Replies)
Discussion started by: gstuart
9 Replies
4. Shell Programming and Scripting
Search and Replace a string pattern with empty in an xml file in unix:
My xml file would be like this :
<Accounts><Name>Harish</Name><mobile>90844444444444445999 </mobile><TRIG>srcujim-1</TRIG></Accounts><Accounts><Name>Satish</Name><mobile>908999</mobile><TRIG>ettertrtt-1</TRIG></Accounts>
... (1 Reply)
Discussion started by: harish_s_ampeo
1 Replies
5. UNIX for Dummies Questions & Answers
Hi
I am looking for a particular string in a file.If the string exists, then I want to replace another string with some other text.Once replaced, search for the same text after that character position in the file. :wall:
E.g: Actual File content:
Hello
Name: Nitin Raj
Welcome to Unix... (4 Replies)
Discussion started by: dashing201
4 Replies
6. Shell Programming and Scripting
I have a list of strings in file:
10 10 AAA
120 13 BBBBB
23 11 CCCCC
11 32 DDDDDD
I want to replace first column of the text such as: 10, 129, 23, 11 with 11, 22, 33, 44.
I can do line by line, but just not sure how to replace partial string without... (1 Reply)
Discussion started by: ford99
1 Replies
7. Shell Programming and Scripting
I have file t1.log
Contents of t1.log file
Number of records processed:
Number of records rejected:
Error :
xyz ..........
abc ..........
aaa _]
start time :
end time :
Please let me know how i can remove the contents highlighted in red in the t1.log file.
Thanks
Sam (3 Replies)
Discussion started by: sam777
3 Replies
8. Shell Programming and Scripting
Hi Guys,
I need replace part of string in a file.
for example:
ABC=123
CDE=122
DEF=456
ABC=123
DED=333
ABC=123
I need replace the value after ABC=, highlighted in red. I want to get following result;
ABC=456
CDE=122
DEF=456
ABC=456
DED=333
ABC=456
Anybody can help me this.
... (8 Replies)
Discussion started by: ken6503
8 Replies
9. UNIX for Dummies Questions & Answers
Hi Everyone,
I have a requirement in ksh where i have a set of files in a directory. I need to search each and every file if a particular string is present in the file, delete that line and replace that line with another string expression in the same file.
I am very new to unix. Kindly help... (10 Replies)
Discussion started by: Pradhikshan
10 Replies
LEARN ABOUT DEBIAN
test::bdd::cucumber::executor
Test::BDD::Cucumber::Executor(3pm) User Contributed Perl Documentation Test::BDD::Cucumber::Executor(3pm)
NAME
Test::BDD::Cucumber::Executor - Run through Feature and Harness objects
VERSION
version 0.11
DESCRIPTION
The Executor runs through Features, matching up the Step Lines with Step Definitions, and reporting on progress through the passed-in
harness.
METHODS
steps
add_steps
The attributes "steps" is a hashref of arrayrefs, storing steps by their Verb. "add_steps()" takes step definitions of the item list form:
(
[ Given => qr//, sub {} ],
),
and populates "steps" with them.
execute
Execute accepts a feature object, a harness object, and an optional Test::BDD::Cucumber::TagSpec object and for each scenario in the
feature which meets the tag requirements (or all of them, if you haven't specified one), runs "execute_scenario".
execute_scenario
Accepts a hashref of options, and executes each step in a scenario. Options:
"feature" - A Test::BDD::Cucumber::Model::Feature object
"feature_stash" - A hashref that should live the lifetime of feature execution
"harness" - A Test::BDD::Cucumber::Harness subclass object
"scenario" - A Test::BDD::Cucumber::Model::Scenario object
"background_obj" - An optional Test::BDD::Cucumber::Model::Scenario object representing the Background
"scenario_stash" - We'll create a new scenario stash unless you've posted one in. This is used exclusively for giving Background sections
access to the same stash as the scenario they're running before.
For each step, a Test::BDD::Cucumber::StepContext object is created, and passed to "dispatch()". Nothing is returned - everything is played
back through the Harness interface.
add_placeholders
Accepts a text string and a hashref, and replaces " <placeholders" > with the values in the hashref, returning a string.
dispatch
Accepts a Test::BDD::Cucumber::StepContext object, and searches through the steps that have been added to the executor object, executing
against the first matching one.
You can also pass in a boolean 'short-circuit' flag if the Scenario's remaining steps should be skipped.
skip_step
Accepts a step-context, a result-type, and a textual reason, exercises the Harness's step start and step_done methods, and returns a
skipped-test result.
AUTHOR
Peter Sergeant "pete@clueball.com"
LICENSE
Copyright 2011, Peter Sergeant; Licensed under the same terms as Perl
perl v5.14.2 2012-05-20 Test::BDD::Cucumber::Executor(3pm)