Sponsored Content
Top Forums Shell Programming and Scripting shell script to edit file and delete entry Post 302234400 by tannu on Tuesday 9th of September 2008 03:04:47 PM
Old 09-09-2008
Hi

Thankyou so much it worked.
 

10 More Discussions You Might Find Interesting

1. AIX

How to edit txt file by shell script?

What I want to do is just delete some lines from a text file, I know it's easy using copy and redirect function, but what I have to do is edit this file (delete the lines) directly, as new lines may be added to the text file during this period. Can AIX do this ? # cat text 1:line1 2:line2... (3 Replies)
Discussion started by: dupeng
3 Replies

2. Shell Programming and Scripting

shell script to edit the content of a file

Hi I need some help using shell script to edit a file. My original file has the following format: /txt/email/myemail.txt /txt/email/myemail2.txt /pdf/email/myemail.pdf /pdf/email/myemail2.pdf /doc/email/myemail.doc /doc/email/myemail2.doc I need to read each line. If the path is... (3 Replies)
Discussion started by: tiger99
3 Replies

3. Shell Programming and Scripting

Edit a config file using shell script

I need to edit a config file using shell script. i.e., Search with the 'key' string and edit the 'value'. For eg: below is what I have in the config file "configfile.cfg". Key1=OldValue1 Key2=OldValue2 I want to search for "Key1" and change "OldValue1" to "NewValue1" Thanks for your... (7 Replies)
Discussion started by: rajeshomallur
7 Replies

4. Shell Programming and Scripting

Edit date entry inside a file

Hi All, I wanted to edit the date value located at /var/opt/CPsuite-R65/fw1/conf/local.scv. The date entry looks like this : :Signature (">=20100717") How can I update the date value by 1 day every other day while preserving the margins of the whole file in a shell script? I have... (5 Replies)
Discussion started by: achillesxv
5 Replies

5. Shell Programming and Scripting

Shell script to edit a file

Hello, I have a big file in wich I would like to rename inside this exactly the string '_ME' and not rename in case we have 'ABC_MELANGE'. Is there a way to do it by using a shell script? Any tip will be apreciated. The file is like described bellow, after using command more filename : ... (3 Replies)
Discussion started by: Titas
3 Replies

6. Shell Programming and Scripting

How to edit file to have one line entry?

Hello All, My file content is: DROP TABLE "FACT_WORLD"; CREATE TABLE "FACT_WORLD" ( "AR_ID" INTEGER NOT NULL, "ORG_ID" INTEGER NOT NULL ) DATA CAPTURE NONE COMPRESS YES; I want to change this file to have entries in one... (6 Replies)
Discussion started by: akash2508
6 Replies

7. Shell Programming and Scripting

shell script to edit a file

i have a file called number which contains data as 1 2 3 4 5 6 7 8 9 0 9 8 7 6 5 4 3 2 1 0 0 1 2 3 4 needed a shell script to print the output as 1 7 7 1 4 and (2 Replies)
Discussion started by: jacky29
2 Replies

8. Shell Programming and Scripting

How to update an entry of another file in a Shell script?

Hi all, Say I have a shell script called update_password.sh - in this script I want to perform a task to update a specified entry of another file (e.g. users.passpords) update_password.sh #!/bin/bash -e PW_FILE_DIR="${A_DIR}/.../..." PW_FILE="users.passwords" I want to update the... (2 Replies)
Discussion started by: isaacniu
2 Replies

9. Homework & Coursework Questions

Edit the file in shell script

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: I am trying to automate hadoop installation procedure using shell script. It involves go to perticular directory... (3 Replies)
Discussion started by: Abdul Navaz
3 Replies

10. How to Post in the The UNIX and Linux Forums

Help me, write a bash script to delete parent entry with all their child entry in LDAP UNIX server

Hi All, Please help me and guide me to write a bash/shell script on Linux box to delete parent entry with all their child entries. example: Parent is : ---------- dn: email=yogesh.kumar@wipro.com, o=wipro, o=in child is: ---------- dn: cn: yogesh kumar, email=yogesh.kumar@wipro.com,... (1 Reply)
Discussion started by: Chand
1 Replies
HTML::AsSubs(3) 					User Contributed Perl Documentation					   HTML::AsSubs(3)

NAME
HTML::AsSubs - functions that construct a HTML syntax tree VERSION
This document describes version 5.03 of HTML::AsSubs, released September 22, 2012 as part of HTML-Tree. SYNOPSIS
use HTML::AsSubs; $h = body( h1("This is the heading"), p("This is the first paragraph which contains a ", a({href=>'link.html'}, "link"), " and an ", img({src=>'img.gif', alt=>'image'}), "." ), ); print $h->as_HTML; DESCRIPTION
This module exports functions that can be used to construct various HTML elements. The functions are named after the tags of the corresponding HTML element and are all written in lower case. If the first argument is a hash reference then it will be used to initialize the attributes of this element. The remaining arguments are regarded as content. For a similar idea (i.e., it's another case where the syntax tree of the Perl source mirrors the syntax tree of the HTML produced), see HTML::Element's "new_from_lol" method. For what I now think is a cleaner implementation of this same idea, see the excellent module "XML::Generator", which is what I suggest for actual real-life use. (I suggest this over "HTML::AsSubs" and over "CGI.pm"'s HTML-making functions.) ACKNOWLEDGEMENT
This module was inspired by the following message: Date: Tue, 4 Oct 1994 16:11:30 +0100 Subject: Wow! I have a large lightbulb above my head! Take a moment to consider these lines: %OVERLOAD=( '""' => sub { join("", @{$_[0]}) } ); sub html { my($type)=shift; bless ["<$type>", @_, "</$type>"]; } :-) I *love* Perl 5! Thankyou Larry and Ilya. Regards, Tim Bunce. p.s. If you didn't get it, think about recursive data types: html(html()) p.p.s. I'll turn this into a much more practical example in a day or two. p.p.p.s. It's a pity that overloads are not inherited. Is this a bug? BUGS
The exported link() function overrides the builtin link() function. The exported tr() function must be called using &tr(...) syntax because it clashes with the builtin tr/../../ operator. SEE ALSO
HTML::Element, XML::Generator html head title base link meta isindex nextid script style body h1 h2 h3 h4 h5 h6 p pre div blockquote a img br hr ol ul dir menu li dl dt dd dfn cite code em kbd samp strong var address span b i u tt center font big small strike sub sup table tr td th caption form input select option textarea object applet param map area frame frameset noframe A bunch of methods for creating tags. Private Functions _elem() The _elem() function is wrapped by all the html 'tag' functions. It takes a tag-name, optional hashref of attributes and a list of content as parameters. AUTHOR
Current maintainers: o Christopher J. Madsen "<perl AT cjmweb.net>" o Jeff Fearn "<jfearn AT cpan.org>" Original HTML-Tree author: o Gisle Aas Former maintainers: o Sean M. Burke o Andy Lester o Pete Krawczyk "<petek AT cpan.org>" You can follow or contribute to HTML-Tree's development at <http://github.com/madsen/HTML-Tree>. COPYRIGHT AND LICENSE
Copyright 1995-1998 Gisle Aas, 1999-2004 Sean M. Burke, 2005 Andy Lester, 2006 Pete Krawczyk, 2010 Jeff Fearn, 2012 Christopher J. Madsen. This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The programs in this library are distributed in the hope that they will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. perl v5.18.2 2017-10-06 HTML::AsSubs(3)
All times are GMT -4. The time now is 01:16 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy