Here are two awk scripts that I think do what you need. Use the 1st script if the field separator in either file is a mixture of spaces and tabs. Use the 2nd script if the field separator in both files is always a single space. In both cases, if you're using a Solaris/SunOS system, use /usr/xpg4/bin/awk, /usr/xpg6/bin/awk, or nawk instead of awk:
Note that the 2nd form sends output to file4 instead of file3 (so you can run both forms and compare the output).
This User Gave Thanks to Don Cragun For This Post:
hi,
i am facing a problem in merging two files using awk,
the problem is as stated below,
file1:
A|B|C|D|E|F|G|H|I|1
M|N|O|P|Q|R|S|T|U|2
AA|BB|CC|DD|EE|FF|GG|HH|II|1
....
....
....
file2 :
1|Mn|op|qr (2 Replies)
Hi
this question applies to Solaris 8,9,10 and opensolaris as in my environment it applies to all of these
Is there a limit on the size of the username (in /etc/passwd) or indeed does there come a point where, like the 8 character limitation of passwords, the system receives the input but... (6 Replies)
Hi there !
I need to treat files with variable line length, and process the tab-delimited words of each line. The tools I know are some basic bash scripting and sed ... I haven't got to python or perl yet.
So my file looks like this
obj1 0.01953 0.34576 0.04418 0.01249
obj2 0.78140... (7 Replies)
Hi all,
Sorry if someone has answered something like this already, but I have a problem. I am not brilliant with "awk" but think it should be the command to use to get what I am after.
I have 2 files:
job-file (several hundred lines like):
1018003,LONG MU WAN,1113S
1018004,LONG MU... (4 Replies)
Hi,
My requirement is,there is a directory location like:
:camp/current/
In this location there can be different flat files that are generated in a single day with same header and the data will be different, differentiated by timestamp, so i need to verify how many files are generated... (10 Replies)
Dear Gents,
Please I need your help... I need small script :) to do the following.
I have a thousand of files in a folder produced daily.
I need first to merge all files called. txt (0009.txt, 0010.txt, 0011.txt) and and to output a resume of all information on 2 separate files in csv... (14 Replies)
I have three files of varying lengths and different number of columns. How can I paste all three with all columns aligned?
File1
----
123
File2
----
234
345
678
File3
----
456
789
Output should look like:
123 234 456
345 789 (6 Replies)
Hi All,
I am trying to obtain count of characters using awk, but "length" function returns a value of 1 for 2-byte or 3-byte characters as well unlike wc -c command.
I have tried to use the below commands within awk function, but it does not seem to work
{
cmd="wc -c "stringtocheck
( cmd )... (6 Replies)
So my program is not working and I keep changing it to figure out why. So I have two questions, can I do tracing similar to bash, and also what is wrong with this.
The idea is simple, I want to count "word" lengths, with the loose definition of word not being a space, tab, or newline. Here is... (11 Replies)
Discussion started by: Riker1204
11 Replies
LEARN ABOUT CENTOS
intltool-merge
INTLTOOL-MERGE(8) System Manager's Manual INTLTOOL-MERGE(8)NAME
intltool-merge - merge translated strings into various types of file
SYNOPSIS
intltool-merge [option]... PO_DIRECTORY FILENAME OUTPUT_FILE
DESCRIPTION
Merge translated strings in po files in PO_DIRECTORY with the original application file FILENAME, and output the file OUTPUT_FILE contain-
ing both original and localized strings.
If FILENAME is an XML file, OUTPUT_FILE will contain repeated xml nodes, where each node contains one of the localized strings with
"xml:lang" attribute.
OPTIONS
Mode of operation
-b
--ba-style
Merge files in bonobo-activation style, which is used for bonobo servers.
-d
--desktop-style
Merge files in desktop style, which is similar to the Windows .ini file format.
-k
--keys-style
Merge files in keys style, which is used for metadata.
-o
--oaf-style
(OBSOLETE) Same as -b/--ba-style.
-r
--rfc822deb-style
Merge files in RFC 822 style, which is usually used in Debian configuration files.
--quoted-style
Merge files in quoted string style, which just translates any strings within "".
-x
--xml-style
Merge files in standard XML style, both as attributes and as raw pcdata.
Other options
-u
--utf8
Convert all strings to UTF-8 before merging.
-p
--pass-through
Use strings as is in .po files without conversion (STRONGLY unrecommended with -x).
-c
--cache
(TBD)
-q
--quiet
Be quiet while running.
-v
--version
Show version information.
-h
--help
Show usage and basic help information.
FILES
po/.intltool-merge-cache
Cache file generated by intltool-merge, that contains all strings in all po files separated by 1.
REPORTING BUGS
Report bugs to http://bugs.launchpad.net/intltool
AUTHOR
Darin Adler <darin@bentspoon.com>
Kenneth Christiansen <kenneth@gnu.org>
Maciej Stachowiak <mjs@eazel.com>
SEE ALSO iconv(1), intltoolize(8), intltool-prepare(8), intltool-extract(8), intltool-update(8)intltool 2003-08-02 INTLTOOL-MERGE(8)