Sponsored Content
Top Forums UNIX for Dummies Questions & Answers analyze lines in a file by loop Post 302589849 by crest.boy on Thursday 12th of January 2012 10:33:06 PM
Old 01-12-2012
Quote:
Originally Posted by itkamaraj
Code:
$ tr " " "\n" < test.txt
#login,full
name,email,project,role,action
gmwen,Bruce
Wen,wengm@foxmail.com,bt,qa,add

Sorry, but what I expected is to avoid the broken issue.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Loop through the lines in a file?

How do I loop through the lines of a file? Each line of the file will be the name of a server. Like: server1.stuff.com server2.stuff.com For each server I want to do a secure copy of the file to the other server. This will be a cron job so I guess it needs to run in just SH. I... (3 Replies)
Discussion started by: jimmy
3 Replies

2. Shell Programming and Scripting

Loop through file and write out lines to file(s)

Hi, I am new to ksh scripting so your help will be much appreciated. I have a file called file.txt which looks like this Header 20050702 20050703 ABC DEF Header 20050703 20050704 123 456 Header 20050704 20050705 XXX YYY What I am trying to do is write out each of the record... (7 Replies)
Discussion started by: Jtrinh
7 Replies

3. Shell Programming and Scripting

How to use while loop in bash shell to read a file with 4 lines of gap

Hi , I am currently using the while loop in bash shell, as follows. while read line do echo $line done < file.txt However, i want to use the while loop on file.txt, which will read the file with 4 lines of gap. Ex- if file.txt is a file of 100 lines, then i want to use the loop such... (3 Replies)
Discussion started by: jitendriya.dash
3 Replies

4. Shell Programming and Scripting

Find and analyze variable Strings in a large file.

Hi guys, I have multiple files (>5000) which I have in a folder. I read every file name and put it in a tmp variable "i" so that i can use it in the following task. I have a large .txt file (>50 MB) in which I want to find the variable "i" and the lines after this variable, so that I can use... (4 Replies)
Discussion started by: Ashitaka007
4 Replies

5. UNIX for Dummies Questions & Answers

How to analyze file hashing

What command should I use to analyze file hashing of fixed flat files. How much work does it take for multiple flat files. (3 Replies)
Discussion started by: jbjoat
3 Replies

6. Programming

Using c++ to analyze two file problem

Hi, I have two files: Input_file1.txt 124 235 152 178 156 142 178 163 159 Input_file2.txt 124|5623 452|6698 178|9995 235|7542 159|8852 (1 Reply)
Discussion started by: cpp_beginner
1 Replies

7. Shell Programming and Scripting

Reading two lines in a while loop and combining the lines

Dear all, I have a file like this: imput scaffold_0 1 scaffold_0 10000 scaffold_0 20000 scaffold_0 25000 scaffold_1 1 scaffold_1 10000 scaffold_1 20000 scaffold_1 23283 and I want the output like this: scaffold_0 1 scaffold_0 10000 scaffold_0 10000 scaffold_0 20000... (6 Replies)
Discussion started by: valente
6 Replies

8. Shell Programming and Scripting

ksh Loop through file one, remove lines from file two

Good Afternoon, I start with a file named biglist.txt. I have another file smallerlist. txt I want to remove the lines from smallerlist.txt from biglist.txt and leave those lines that do not reside in smallerlist.txt. Thanks !! (2 Replies)
Discussion started by: popeye
2 Replies

9. Shell Programming and Scripting

Using sed in a loop/to remove lines contained in variable from file

I've tried numerous commands, but I am not sure how to use sed in a loop. This is what I have: VARZ contains CARD_FILE_LIST and it also contains CARD_FILE_LIST2 so echo "$VARZ" CARD_FILE_LIST CARD_FILE_LIST2 I have a file with 60 lines in /tmp/testfile it and I want those lines deleted... (3 Replies)
Discussion started by: newbie2010
3 Replies

10. UNIX for Advanced & Expert Users

How to analyze sosreport file that I generated.?

Hello Team, Could You give me some hints how I should review the sosreport that I generated? I know how to analysis the SAR files however sosreport is my last hope - python script has hunged and I would like to know the root cause - for this is not performance issue. Thanks in advance! ... (3 Replies)
Discussion started by: nsmcny
3 Replies
exif(n) 							   EXIF parsing 							   exif(n)

_________________________________________________________________

NAME
exif - Tcl EXIF extracts and parses EXIF fields from digital images SYNOPSIS
package require Tcl 8.2 package require exif ?1.1.2? exif::analyze channel ?thumbnail? exif::analyzeFile filename ?thumbnail? exif::fieldnames _________________________________________________________________ DESCRIPTION
The EXIF package is a recoding of Chris Breeze's Perl package to do the same thing. This version accepts a channel as input and returns a serialized array with all the recognised fields parsed out. There is also a function to obtain a list of all possible field names that might be present, which is useful in building GUIs that present such information. COMMANDS
exif::analyze channel ?thumbnail? channel should be an open file handle rewound to the start. It does not need to be seekable. channel will be set to binary mode and is left wherever it happens to stop being parsed, usually at the end of the file or the start of the image data. You must open and close the stream yourself. If no error is thrown, the return value is a serialized array with informative English text about what was found in the EXIF block. Failure during parsing or I/O throw errors. If thumbnail is present and not the empty string it will be interpreted as the name of a file, and the thumbnail image contained in the exif data will be written into it. exif::analyzeFile filename ?thumbnail? This is a file-based wrapper around exif::analyze. Instead of taking a stream it takes a filename and analyzes the contents of the specified file. exif::fieldnames This returns a list of all possible field names. That is, the array returned by exif::analyze will not contain keys that are not listed in the return from exif::fieldnames. Of course, if information is missing in the image file, exif::analyze may not return all the fields listed in the return from exif::fieldnames. This function is expected to be primarily useful for building GUIs to display results. N.B.: Read the implementation of exif::fieldnames before modifying the implementation of exif::analyze. COPYRIGHTS
(c) 2002 Darren New Hold harmless the author, and any lawful use is allowed. ACKNOWLEDGEMENTS
This code is a direct translation of version 1.3 of exif.pl by Chris Breeze. See the source for full headers, references, etc. BUGS, IDEAS, FEEDBACK This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category exif of the Tcllib SF Trackers [http://sourceforge.net/tracker/?group_id=12883]. Please also report any ideas for enhancements you may have for either package and/or documentation. exif 1.1.2 exif(n)
All times are GMT -4. The time now is 09:26 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy