04-20-2009
Substitute the space(s) with the + symbol, and do an expr on it ...
Got it ?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I want to add a line at the beginning and at the end of a file..
e.g.
echo "at the beginning.." > tmp_file &&
cat file >> tmp_file &&
echo "last line" >> tmp_file &&
mv tmp_file file
is there a nice way for doing that??
Thx (2 Replies)
Discussion started by: andy2000
2 Replies
2. Shell Programming and Scripting
Hi guys,
How to add a line before a specific line (identified with the starting work ex: xxx) of a file and write it back to the same file?
Thanks (12 Replies)
Discussion started by: mwrg
12 Replies
3. Shell Programming and Scripting
i am writing a script which will let user to input a line.
i m not sure how do i add this line to the end of a txt file ? (8 Replies)
Discussion started by: 76455
8 Replies
4. Shell Programming and Scripting
Hi! I'm trying to assign line numbers to each line of the file
for example consider the following..
The contents of the input file are
hello how are you?
I'm fine.
How about you?
I'm trying to get the following output..
1 hello how are you?
2 I'm fine.
3 How about you? ... (8 Replies)
Discussion started by: abk07
8 Replies
5. Shell Programming and Scripting
Hi All,
I have a file which has some Linux commands in every line like
more 456.dat
more 3232.dat
more 433.dat
I want to add texts like this at the end of every line:
more 456.dat > 1.txt
more 3232.dat > 2.txt
more 433.dat > 3.txt
So, that the result of more goes into 1.txt... (1 Reply)
Discussion started by: shoaibjameel123
1 Replies
6. Shell Programming and Scripting
Hello Everyone,
I need a help from experts of this community regarding one of the issue that I am facing with shell scripting.
My requirement is to append char's at the end of each line of a file. The char that will be appended is variable and will be passed through command line.
The... (20 Replies)
Discussion started by: Sourav Das
20 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I would like to add a new column containing the row numbers to a text file. How do I go about doing that? Thanks!
Example input:
A X
B Y
C D
Output:
A X 1
B Y 2
C D 3 (5 Replies)
Discussion started by: evelibertine
5 Replies
8. Shell Programming and Scripting
Hi again. Sorry for all the questions — I've tried to do all this myself but I'm just not good enough yet, and the help I've received so far from bartus11 has been absolutely invaluable. Hopefully this will be the last bit of file manipulation I need to do.
I have a file which is formatted as... (4 Replies)
Discussion started by: crunchgargoyle
4 Replies
9. Shell Programming and Scripting
Hi everyone,
currently I writing a script for comparing 2 variable in 2 line then output the line with equal value to new file. However, the new file only contain last line only, the earlier line was delete. I do google my problem but still not find the way out. Sorry for my English.
Thank you... (10 Replies)
Discussion started by: lazy_bear
10 Replies
10. Shell Programming and Scripting
I have a shell script that looks something like the following:
mysql -uroot db1 < db1.sql
mysql -uroot db2 < db2.sql
mysql -uroot db3 < db3.sql
mysql -uroot db4 < db4.sql
....
different db names in more than 160 lines.
I want to run this script with nohup and have a status later.
So,... (6 Replies)
Discussion started by: MKH
6 Replies
LEARN ABOUT SUNOS
wnn_hinsi.data
wnn_hinsi.data(4) File Formats wnn_hinsi.data(4)
NAME
wnn_hinsi.data - Wnn6 part of speech administration file
SYNOPSIS
/usr/lib/locale/ja/wnn/ja/hinsi.data
DESCRIPTION
hinsi.data is a file that contains information required to administer the main parts of speech.
Numbers are allocated in the order of the parts of speech and composite parts of speech defined in hinsi.data. These numbers are used
when creating dictionary files and part of speech files, when looking up part of speech names by numbers from the client and server, and
looking up the parts of speech in composite parts of speech. Numbers are assigned in ascending order starting at 0.
Only the following operations are allowed for this file: appending new parts of speech or composite parts of speech to the end of the file
and replacing lines consisting of only "@" with definitions of parts of speech or composite parts of speech. NEVER DELETE ENTRIES. "@" is
used to reserve lines in the file in advance when part of speech names have not yet been determined.
The part of speech formats for lines in this file are as follows:
part_of_speech
composite_part_of_speech $ part_of_speech : part_of_speech:...:part_of_speech
All parts of speech appearing in definitions of composite parts of speech must be defined before the composite part of speech can be
defined. There must not be more than one part of speech or composite part of speech with the same name.
Everything on a line following a semicolon (;) is treated as comment and ignored.
Information on this file (looking up part of speech names from part of speech numbers and looking up the structural elements of composite
parts of speech) are provided by the library and can thus be referenced through the client process.
EXAMPLES
Example 1:
[SENTOU] ;Beginning of a sentence
[MEISHI] ;Indicates a noun.
[ICHIDAN]
[ICHIDANMEI]$[ICHIDAN]:[MEISHI] ;A composite part of speech
@
@
NOTES
Information on the main parts of speech must be consistent between all dictionaries and connection information files. Do not edit and
change hinsi.data. (If the file is changed, the meaning of the part of speech numbers in dictionaries and connection information files
created with the old part of speech administration file will change.)
SunOS 5.10 28 May 1998 wnn_hinsi.data(4)