Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Need an awk command to delete a line Post 302771104 by Rahul619 on Tuesday 19th of February 2013 04:27:51 PM
Old 02-19-2013
Hi ..Yes,am able 2 copy that error line to a separate file. My requirement is like I want that error line alone to be deleted from the main file so that I can process the main file for my purpose again ..
Please help me out ..
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

awk : delete ^M at the end of the line

Hi all, I'm newbi in scripting. could someone tell how to delete the ^M at the end of the linie with an awk command. many thanks in advance. (2 Replies)
Discussion started by: liliput
2 Replies

2. UNIX for Dummies Questions & Answers

delete contents from command line

How might I delete the contents of a file from the command line? (not delete the file) (4 Replies)
Discussion started by: juanbro
4 Replies

3. Shell Programming and Scripting

how to delete line with awk

Hi I have a multi -line file which is sorted by the 1-st colomn in the following format: 400 0000 0001 1000 1010 0111 0000 1000 0000 402 1101 0000 1100 1010 0111 1000 1000 0000 403 1001 0000 1100 1010 0111 0000 1000 0000 495 1000 0000 1100 1010 0111 0000 1000 0000 500 0000 0001 1000 0010... (2 Replies)
Discussion started by: aoussenko
2 Replies

4. Shell Programming and Scripting

SED delete only first line command - Help need

Can any one help me how the sed delete only first line command (D) works. sed -f sedcmds File.txt In this how the sed delete only first line command (D) works to delete the blank lines appearing more than ones leaving only one blank and deleting others blanks. While doing step by step when... (2 Replies)
Discussion started by: gwgreen1
2 Replies

5. Shell Programming and Scripting

delete more than one line awk or perl

Hi all! How can a file be rid of three lines in sequence like the sample below: ... </s> <s> <w></w> </s> <s> ...to get: ... </s> <s> ... Note that the digits between square brackets may be more than one, comprising a comma, or a full-stop; and that the string between brackets... (1 Reply)
Discussion started by: mjomba
1 Replies

6. Shell Programming and Scripting

sed command to delete line

HI, Im using the below commmand to delete lines having "(" at the start of a line. sed -e '/^(/d' But i need a command to delete lines that has only "(" in it and no other strings. infile - asdf asdf ( asdf ( asd outfile (1 Reply)
Discussion started by: dvah
1 Replies

7. Shell Programming and Scripting

Delete specific line in awk

Hi, I'm totally new to awk, so thanks in advance for your help. I want to make a csv file out of a text file I've exported from a database I want to do two things: 1. Change pipes ("|") to commas (",") to make a text file into CSV 2. Remove the second line of the file, which is useless junk. ... (3 Replies)
Discussion started by: pip56789
3 Replies

8. Shell Programming and Scripting

sed command to delete everything after > on line

I have a large data file that I need to edit. There are lines like, > <IDNUMBER> (ST000002) > <SUPPLIER> (ST000002) > <IDNUMBER> (ST000004) > <SUPPLIER> (ST000004) and I need to delete everything after the >, excepting the end of line. > <IDNUMBER> > <SUPPLIER> > <IDNUMBER> > ... (4 Replies)
Discussion started by: LMHmedchem
4 Replies

9. UNIX for Dummies Questions & Answers

Using awk to delete a certain line

Ok I have a file that contains #num.txt 1 2 3 4 5 6 7 8 9 my script main.sh checks to see if the first two arguments exist in a seperate file and the third argument would be the value in the num.txt so when i execute $ main.sh name place 5 how would i go about deleteing the... (13 Replies)
Discussion started by: austing5
13 Replies

10. Shell Programming and Scripting

sed command to grep multiple pattern present in single line and delete that line

here is what i want to achieve.. i have a file with below contents cat fileName blah blah blah . .DROP this REJECT that . --sport 7800 -j REJECT --reject-with icmp-port-unreachable --dport 7800 -j REJECT --reject-with icmp-port-unreachable . . . more blah blah blah --dport 3306... (14 Replies)
Discussion started by: vivek d r
14 Replies
Tcl_AppInit(3)						      Tcl Library Procedures						    Tcl_AppInit(3)

__________________________________________________________________________________________________________________________________________________

NAME
Tcl_AppInit - perform application-specific initialization SYNOPSIS
#include <tcl.h> int Tcl_AppInit(interp) ARGUMENTS
Tcl_Interp *interp (in) Interpreter for the application. _________________________________________________________________ DESCRIPTION
Tcl_AppInit is a "hook" procedure that is invoked by the main programs for Tcl applications such as tclsh and wish. Its purpose is to allow new Tcl applications to be created without modifying the main programs provided as part of Tcl and Tk. To create a new application you write a new version of Tcl_AppInit to replace the default version provided by Tcl, then link your new Tcl_AppInit with the Tcl library. Tcl_AppInit is invoked by Tcl_Main and Tk_Main after their own initialization and before entering the main loop to process commands. Here are some examples of things that Tcl_AppInit might do: [1] Call initialization procedures for various packages used by the application. Each initialization procedure adds new commands to interp for its package and performs other package-specific initialization. [2] Process command-line arguments, which can be accessed from the Tcl variables argv and argv0 in interp. [3] Invoke a startup script to initialize the application. Tcl_AppInit returns TCL_OK or TCL_ERROR. If it returns TCL_ERROR then it must leave an error message in for the interpreter's result; otherwise the result is ignored. In addition to Tcl_AppInit, your application should also contain a procedure main that calls Tcl_Main as follows: Tcl_Main(argc, argv, Tcl_AppInit); The third argument to Tcl_Main gives the address of the application-specific initialization procedure to invoke. This means that you do not have to use the name Tcl_AppInit for the procedure, but in practice the name is nearly always Tcl_AppInit (in versions before Tcl 7.4 the name Tcl_AppInit was implicit; there was no way to specify the procedure explicitly). The best way to get started is to make a copy of the file tclAppInit.c from the Tcl library or source directory. It already contains a main procedure and a template for Tcl_AppInit that you can modify for your application. KEYWORDS
application, argument, command, initialization, interpreter Tcl 7.0 Tcl_AppInit(3)
All times are GMT -4. The time now is 12:34 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy