11-08-2019
@Rudic : I am looking for solution for both the scenario's.
--- Post updated at 12:13 PM ---
@Rudic : For scenario-1, it is not working as expected. Instead of comparing the existing one, it is appending the strings in first line.
For scenario-2 which you have said initially worked partially. i.e. For partially matching pattern it updated with new strings which we passed as Input parameter. If the complete strings is not matched then it has to be added to the file as new record which doesn't work.
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
make_strings
make_strings(1) GNUstep System Manual make_strings(1)
NAME
make_strings - tool to build lists of localizable strings from Objective-C files
SYNOPSIS
make_strings [--help] [--verbose] [--aggresive-import] [--aggressive-match] [--aggressive-remove] [-L languages] files.[hmc...]
DESCRIPTION
make_strings parses Objective-C files and builds lists of localizable strings. It then creates new .strings files or merges the strings
with existing .strings files. It's fairly intelligent when matching old and new strings, and produces .strings files that are (supposed to
be) easy for a translator to work with.
make_strings accepts the following options:
OPTIONS
--help Prints a short list of available options.
--verbose
Prints additional information while processing.
-L languages
Specify which languages to process. Multuple -L options are accepted, or multiple languages defined in one -L flag.
--aggressive-import
Activates --aggresive-match and automatically removes "dummy" entries that are added by importing .strings files which were not cre-
ated by make_strings program. This option is suitable when make_strings is run for the first time and there is an existing .strings
file which contains a fairly accurate translation.
--aggressive-match
This option will make make_strings assume that matching keys should have matching translations. This can save lots of work, but it
increases the risk of erroneous translation.
--aggressive-remove
Removes obsolete strings/keys.
EXAMPLES
make_strings -L "English Swedish Russian" *.[hm]
SEE ALSO
GNUstep(7).
AUTHORS
make_strings was written Alexander Malmberg <alexander@malmberg.org>.
This manual page was added by Yavor Doganov <yavor@gnu.org>.
COPYRIGHT
Copyright (C) 2009 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.
GNUstep August 16, 2009 make_strings(1)