Sponsored Content
Top Forums Shell Programming and Scripting How to convert a txt file to xml file Post 302347623 by blitzer on Wednesday 26th of August 2009 06:48:39 AM
Old 08-26-2009
Code:
echo '<?xml version="1.0" encoding="UTF-8"?>' > outfile.txt && echo "<documentbody>$(cat infile.txt)</documentbody>" >> outfile.txt

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Plz Help To convert xml file to text file using bourn shell scripts

If someone out there could help me out with this problem. I would really appreciate it. I am trying to convert xml into text file(fixed length) using Unix Borne shell scripts. My xml file: <root> <header_rec recordtype="00"> <record_id>00</record_id> <country_code>AK></country_code>... (0 Replies)
Discussion started by: ram2s2001
0 Replies

2. Shell Programming and Scripting

Convert XML file into TEXT file using PERL seript

Dear Yogesh..."Convert XML file into TEXT file using PERL seript"... can u help me regarding this issue...plz Thanks Rudro (0 Replies)
Discussion started by: Rudro
0 Replies

3. Shell Programming and Scripting

convert a txt file to xls file

How to convert a txt file(tab delimiter) to xls file. Looking forward help. Thanks, Venkatesh. (2 Replies)
Discussion started by: venkatesht
2 Replies

4. UNIX for Dummies Questions & Answers

To convert a txt file to .xls file

i want to convert a comma seprated file into a .xls file the file contains 3 fields seprated by a comma. i want to convert it into a .xls file with 3 columns and 37 rows DPRPT400,01/15/2009-15:03:06,01/15/2009-15:03:08 DPRPT401,01/15/2009-15:03:15,01/15/2009-15:03:32... (11 Replies)
Discussion started by: manit
11 Replies

5. Shell Programming and Scripting

PERL:How to convert numeric values txt file to PACKED DECIMAL File?

Is there any way to convert numeric values txt file to PACKED DECIMAL File using PERL. Regards, Alok (1 Reply)
Discussion started by: aloktiwary
1 Replies

6. Shell Programming and Scripting

How to convert a .log file into .txt file under unix??

Hi Friends, I have a .log file generated from a tool(Windows PC) which can be opened using a notepad, but when I tried to view the file in unix (cygwin on my laptop) the file type is showing as binary file, So I am unable to process the file. I need to extract some of the selected text... (3 Replies)
Discussion started by: ks_reddy
3 Replies

7. Shell Programming and Scripting

Replace the .txt file between two strings in XML file

Hi i am having XML file with many number of lines,I need to replace between two strings with .txt file using awk. For ex <PersonInfoShipTo ------------------------------ /> My requirement is to replace the content between <PersonInfoShipTo ------------------------------ /> help me. Thanks... (9 Replies)
Discussion started by: Padmanabhan
9 Replies

8. UNIX for Dummies Questions & Answers

Cannot convert this .pages file to a .txt file?!?

I'm trying to use the textutil feature in terminal to convert this .pages file to a .txt file. I've succeeded converting other files like .doc or .docx over to a .txt but this one in particular is giving me headache. I changed the permission rights to 755 but I don't think that mattered to begin... (1 Reply)
Discussion started by: syregnar86
1 Replies

9. UNIX for Advanced & Expert Users

Convert CSV file to nested XML file using UNIX/PERL?

we have a CSV which i need to convert to XML using Perl or Unix shell scripting. I was able to build this XML in oracle database. However, SQL/XML query is running for long time. Hence, I'm considering to write a Perl or shell script to generate this XML file. Basically need to build this XML... (3 Replies)
Discussion started by: laknar
3 Replies

10. UNIX for Beginners Questions & Answers

Convert a txt file to a CSV file

Hi , I have a Txt file which consist of 1000's of SOAP request and response and i want the file to be converted to a csv file like column a should have a soap request and column b should have the soap response . can someone assist me in achieving this please ? Thanks (2 Replies)
Discussion started by: kumarm8
2 Replies
SC_ALLY(1)						    BSD General Commands Manual 						SC_ALLY(1)

NAME
sc_ally -- scamper driver to run Ally on a list of candidate aliases. SYNOPSIS
sc_ally [-?D] [-i infile] [-o outfile] [-p port] [-U unix-socket] [-w waittime] [-q attempts] [-t logfile] DESCRIPTION
The sc_ally utility provides the ability to connect to a running scamper(1) instance and have a set of IPv4 address-pairs testsed for aliases using the Ally technique. For each address pair in the file, sc_ally establishes which probe methods (UDP, TCP-ack, ICMP-echo) solicit an incrementing IP-ID value, and then uses the Ally technique on pairs where a probe method is able to obtain an incrementing IP-ID for both addresses. The output is written to a warts file. The options are as follows: -? prints a list of command line options and a synopsis of each. -D causes sc_ally to detach and become a daemon. -i infile specifies the name of the input file which consists of a sequence of IPv4 address-pairs, one pair per line. -o outfile specifies the name of the output file to be written. The output file will use the warts format. -p port specifies the port on the local host where scamper(1) is accepting control socket connections. -U unix-socket specifies the name of a unix domain socket where scamper(1) is accepting control socket connections. -w waittime specifies the minimum length of time, in seconds, to wait between completing a measurement to a particular IP address and issuing the next. -q attempts specifies the number of times to try Ally when one of the addresses is unresponsive. -t logfile specifies the name of a file to log output from sc_ally generated at run time. EXAMPLE
Given a set of IPv4-address pairs in a file named infile.txt: 192.0.2.1 192.0.32.10 192.0.2.2 192.0.31.8 192.0.2.3 192.0.30.64 and a scamper(1) daemon listening on port 31337, then these address-pairs can be tested for aliases using sc_ally -i infile.txt -o outfile.warts -p 31337 SEE ALSO
N. Spring, R. Mahajan, and D. Wetherall, Measuring ISP topologies with Rocketfuel, Proc. ACM SIGCOMM 2002. scamper(1), sc_wartsdump(1), sc_warts2text(1) AUTHORS
sc_ally is written by Matthew Luckie <mjl@luckie.org.nz>. BSD
March 1, 2011 BSD
All times are GMT -4. The time now is 10:06 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy