Hi
It is possible with sed to print a pattern within a line matching regexp?
So, the line looks like : 19:00:00 blablablabla jobid 2345 <2>
the regexp is "jobid 2345" and the pattern is 56434.
That the code for find... (2 Replies)
Dear Experts,
I have many alarms appeared in a file twice, i want to grep them with this info EVTTIME & DOMAIN, and print them in second file with 1 occurance.
I have tried uniq -d test.txt > newfile and awk '!arr++' test.txt > newfile both are not working
Please help me with this!!!
... (1 Reply)
Hi :),
I am using the script to search "MYPATTERN" in MYFILE and print that block of lines containing the pattern starting with HEADER upto FOOTER.
But my problem is that at some occurrence my footer is different e.g. ";". How to modify the script so that MYPATTERN between HEADER and different... (1 Reply)
Dear Experts,
I have file called file1 in which i am greping a pattern after that i want to next 3 lines when that pattern is matched.
Ex:- file1
USA
UK
India
Africa
Hello
Asia
Europe
Australia
Hello
Peter
Robert
Jo
i want to next 3 lines after matching Hello... (12 Replies)
Hi Friends,
I am working on a script.. Looking forward for your expert help.....
My requirement is:
I have a text file where, need to search equip * RTF or end of line with RTF ,once this pattern is found then print 2nd line, 6th line, 7th line to a different file.
For Ex:
equip 1... (34 Replies)
Hi,
i have data file like:
START1
a
b
STOP
c
d
START2
e
STOP
f
START3
g
STOP
When one of the START<count> variable is passed, i should print all lines matching this until the first 'STOP'
for example if 'START2' is provided for match, i should get the result as:
START2 (1 Reply)
Hi,
I want to match the pattern in file1 with file2 and print the value in file2 and paste in file1
file1:
ISHO RT SR Major 96.46778
Drop Call Rate CS Critical 0.5072662
ISHO RT SR Major 97.754364... (3 Replies)
Hi all,
I want to search for strings in file1 that can be found in file2 and print out the whole line when matching pattern is found.
I have used the below command, but this is not working for me, because it is writing out only the matching patterns from file2, not the whole line.
fgrep -o... (2 Replies)
would like to print everything after matching two patterns AAA and BBB.
output :
CCC
ZZZ
sample data :
AAA
BBB
CCC
ZZZ (4 Replies)
Discussion started by: jhonnyrip
4 Replies
LEARN ABOUT OSX
ipentry
ipentry(n) An IP address entry widget ipentry(n)
__________________________________________________________________________________________________________________________________________________NAME
ipentry - An IP address entry widget
SYNOPSIS
package require Tcl 8.4
package require Tk 8.4
package require ipentry ?0.3?
::ipentry::ipentry pathName ?option value...?
::ipentry::ipentry6 pathName ?option value...?
pathName complete
pathName get
pathName insert iplist
pathName icursor index
pathName configure option value...
pathName cget option
_________________________________________________________________DESCRIPTION
This package provides a widget for the entering of a IP address.
::ipentry::ipentry pathName ?option value...?
Creates a new IPv4 ipentry widget and configures it with the given options and their values.
::ipentry::ipentry6 pathName ?option value...?
Creates a new ipentry widget for the entry of an IPv6 address. All options are the same as the IPv4 widget.
Each widget created with the command above supports the following methods:
pathName complete
Returns a boolean value. True indicates that the entry contains a complete IP address, meaning all fields have a value. In some
cases IPv6 address are valid when fields are missing. You will need to do your own validation to detect this.
pathName get
Returns the contents of the entry as a list consisting of 4 or 8 elements.
pathName insert iplist
IPv4 Takes a list of 4 elements and inserts one into each quad of the entry, in order. All values in the list must be empty or
integers. Values outside the range 0 to 255 are modified to be within the range. IPv6 Takes a list of 8 elements and inserts one
into each quad of the entry, in order. All values in the list must be empty or 1 to 4 hex digits.
pathName icursor index
Sets the position of the widgets insertion cursor. Only integer values between 0 and 15 are valid for ipentry and 0 to 31 for ipen-
try6. Setting the icursor will only have an effect if the widget already has the input focus.
pathName configure option value...
Modifies the configuration of the widget. For options and their meaning see the widget options section.
pathName cget option
Returns information about the current configuration of the widget, for the specified option. For options and their meaning see the
widget options section.
WIDGET OPTIONS
Command-Line Switch: -textvariable
Database Name: textvariable
Database Class: Variable
The name of a variable which holds the value of the IP address. The value must be a string of the form NNN.NNN.NNN.NNN for IPv4 or
HHHH:HHHH:HHHH:HHHH:HHHH:HHHH:HHHH:HHHH for IPv6 where H is a hex digit. The variable will be modified to represent a valid IP
address if it is not already.
Command-Line Switch: -state
Database Name: state
Database Class: State
Specifies one of three states for the entry: normal, disabled, or readonly.
Command-Line Switch: -font
Database Name: font
Database Class: Font
Command-Line Switch: -bd
Database Name: borderWidth
Database Class: BorderWidth
Command-Line Switch: -fg
Database Name: foreground
Database Class: Foreground
Command-Line Switch: -bg
Database Name: background
Database Class: Background
Command-Line Switch: -relief
Database Name: relief
Database Class: Relief
Command-Line Switch: -highlightthickness
Database Name: highlightThickness
Database Class: HighlightThickness
Command-Line Switch: -highlightcolor
Database Name: highlightColor
Database Class: HighlightColor
Command-Line Switch: -highlightbackground
Database Name: highlightBackground
Database Class: HighlightBackground
Command-Line Switch: -selectbackground
Database Name: selectBackground
Database Class: Background
Command-Line Switch: -selectforeground
Database Name: selectForeground
Database Class: Foreground
Command-Line Switch: -selectborderwidth
Database Name: selectBorderWidth
Database Class: BorderWidth
Command-Line Switch: -disabledbackground
Database Name: disabledBackground
Database Class: DisabledBackground
Command-Line Switch: -disabledforeground
Database Name: disabledForeground
Database Class: DisabledForeground
Command-Line Switch: -readonlybackground
Database Name: readonlyBackground
Database Class: ReadonlyBackground
Command-Line Switch: -insertbackground
Database Name: insertBackground
Database Class: Background
Standard widget options. See options for a description of their meanings and values.
KEYWORDS
entry, ip address
ipentry 0.3 ipentry(n)