Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Breaking up a text file into lines Post 302550677 by alister on Friday 26th of August 2011 05:17:42 PM
Old 08-26-2011
Code:
tr : '\n' <infile >outfile

Regards,
Alister
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Breaking long lines into (characters, newline, space) groups

Hello, I am currently trying to edit an ldif file. The ldif specification states that a newline followed by a space indicates the subsequent line is a continuation of the line. So, in order to search and replace properly and edit the file, I open the file in textwrangler, search for "\r " and... (14 Replies)
Discussion started by: rowie718
14 Replies

2. Shell Programming and Scripting

how to get the no. of lines in a text file

Hi, I want to count the no. of lines in a text file and print only the count(without file name) in another file with the prefix 'Count:'. I'm able to count the no. of lines present in the file using wc -l <filename> but i have to subtract one from the count and print as i dont need to... (8 Replies)
Discussion started by: vimalr
8 Replies

3. Shell Programming and Scripting

[bash help]Adding multiple lines of text into a specific spot into a text file

I am attempting to insert multiple lines of text into a specific place in a text file based on the lines above or below it. For example, Here is a portion of a zone file. IN NS ns1.domain.tld. IN NS ns2.domain.tld. IN ... (2 Replies)
Discussion started by: cdn_humbucker
2 Replies

4. UNIX for Dummies Questions & Answers

How to grep multiple lines from a text file using another text file?

I would like to use grep to select multiple lines from a text file using a single-column text file. Basically I want to only select lines from the first text file where the second column of the first text file matches the second text file. How do I go about doing that? Thanks! (5 Replies)
Discussion started by: evelibertine
5 Replies

5. Shell Programming and Scripting

Breaking lines which contains more than 50 characters in a file

Hi, I have a file which contains many lines. Some of them are longer than 50 chars. I want to break those lines but I don't want to break words, e.g. the file This is an exemplary text which should be broken aaaaaa bbbbb ccccc This is the second line This line should also be broken... (3 Replies)
Discussion started by: wenclu
3 Replies

6. UNIX for Dummies Questions & Answers

Extracting lines from a text file based on another text file with line numbers

Hi, I am trying to extract lines from a text file given a text file containing line numbers to be extracted from the first file. How do I go about doing this? Thanks! (1 Reply)
Discussion started by: evelibertine
1 Replies

7. Shell Programming and Scripting

How to delete lines of a text file based on another text file?

I have 2 TXT files with with 8 columns in them(tab separated). First file has 2000 entries whereas 2nd file has 300 entries. The first file has ALL the lines of second file. Now I need to remove those 300 lines (which are in both files) from first file so that first file's line count become... (2 Replies)
Discussion started by: prvnrk
2 Replies

8. Shell Programming and Scripting

Read n lines from a text files getting n from within the text file

I dont even have a sample script cause I dont know where to start from. My data lookes like this > sat#16 #data: 15 site:UNZA baseline: 205.9151 0.008 -165.2465 35.8109 40.6685 21.9148 121.1446 26.4629 -18.4976 33.8722 0.017 -165.2243 48.2201 40.6908 ... (8 Replies)
Discussion started by: malandisa
8 Replies

9. UNIX for Dummies Questions & Answers

Add strings from one file at the end of specific lines in text file

Hello All, this is my first post so I don't know if I am doing this right. I would like to append entries from a series of strings (contained in a text file) consecutively at the end of specifically labeled lines in another file. As an example: - the file that contains the values to be... (3 Replies)
Discussion started by: gus74
3 Replies

10. Shell Programming and Scripting

Match text to lines in a file, iterate backwards until text or text substring matches, print to file

hi all, trying this using shell/bash with sed/awk/grep I have two files, one containing one column, the other containing multiple columns (comma delimited). file1.txt abc12345 def12345 ghi54321 ... file2.txt abc1,text1,texta abc,text2,textb def123,text3,textc gh,text4,textd... (6 Replies)
Discussion started by: shogun1970
6 Replies
CTFMERGE(1)						    BSD General Commands Manual 					       CTFMERGE(1)

NAME
ctfmerge -- merge several CTF data sections into one SYNOPSIS
ctfmerge [-fgstv] -l label -L labelenv -o outfile file ... ctfmerge [-fgstv] -l label -L labelenv -o outfile -d uniqfile [-g] [-D uniqlabel] file ... ctfmerge [-fgstv] -l label -L labelenv -o outfile -w withfile file ... ctfmerge [-g] -c srcfile destfile DESCRIPTION
The ctfmerge utility merges several CTF data sections from several files into one output file, unifying common data. The following options are available: -f Match global symbols to global CTF data. -g Don't delete the original debugging sections. -s Use the .dynsym ELF section instead of the .symtab ELF section. -t Make sure that all object files have a CTF section. -v Enable verbose mode. -l label Sets the label as label. -L labelenv Instructs ctfmerge to read the label from the environment variable labelenv. -o outfile Use outfile to store the merged CTF data. -d uniqfile Uniquify against uniqfile. -d uniqlabel Uniquify against label uniqlabel -w withfile Additive merge with withfile. -c srcfile destfile Copy CTF data from srcfile into destfile. EXIT STATUS
The ctfmerge utility exits 0 on success, and >0 if an error occurs. SEE ALSO
ctfconvert(1), ctfdump(1) HISTORY
The ctfmerge utility first appeared in FreeBSD 7.0. AUTHORS
The CTF utilities came from OpenSolaris. BSD
July 7, 2010 BSD
All times are GMT -4. The time now is 03:08 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy