06-20-2013
Could you show/post input sample/s? That will make things a lot better.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
I've been experiencing a difficulty trying to match a number and write it to a new file.
My input file is: input.txt
It contains the lines:
103P 123587.256971 3.21472112 3.1517423
1.05897234566427 58.2146258 12.35478 25.3612489
What would be the sed command to... (17 Replies)
Discussion started by: Biederman
17 Replies
2. Shell Programming and Scripting
Hi,
I would like to use SED to do the following string replacement:
asd1abc to www1cda
asd2abc to www2cda
...
asd9abc to www9cda
I can use 'asd.abc' to find the orignal string, however I don't know how to generate the target string. Any suggestion?
Thanks,
... (2 Replies)
Discussion started by: mail4mz
2 Replies
3. Shell Programming and Scripting
i need to search for a pattern from a big file and print everything expect the next 6 lines from where the pattern match was made. (8 Replies)
Discussion started by: chidori
8 Replies
4. UNIX for Dummies Questions & Answers
How can I write a script that takes a cisco config file and outputs every occurrence of two, or more, pattern matches through the whole config file?
For example, out of a config file, i want to print out every line with interface, description and ip address through the whole file, and disregard... (3 Replies)
Discussion started by: knownasthatguy
3 Replies
5. Shell Programming and Scripting
I have following pattern in a file:
00:01:38 UTC
abcd
00:01:48 UTC
00:01:58 UTC
efgh
00:02:08 UTC
00:02:18 UTC
and I need to change something like the following
00:01:38 UTC
abcd
00:01:48 UTC
XXXX
00:01:58 UTC
efgh
00:02:08 UTC
XXXX (6 Replies)
Discussion started by: jjnight
6 Replies
6. UNIX for Dummies Questions & Answers
Hi experts , im new to Unix,AWK ,and im just not able to get this right.
I need to match for some patterns if it matches I need to print the next few words to it.. I have only three such conditions to match… But I need to print only those words that comes after satisfying the first condition..... (2 Replies)
Discussion started by: 100bees
2 Replies
7. Shell Programming and Scripting
Im using the command below , but thats not the output that i want. it only prints the odd and even numbers.
awk '{if(NR%2){print $0 > "1"}else{print $0 > "2"}}'
Im hoping for something like this
file1:
Text hi this is just a test
text1 text2 text3 text4 text5 text6
Text hi... (2 Replies)
Discussion started by: invinzin21
2 Replies
8. Shell Programming and Scripting
Hello Experts , require help . See below output:
File inputs
------------------------------------------
Server Host = mike
id rl images allocated last updated density
vimages expiration last read <------- STATUS ------->... (4 Replies)
Discussion started by: tigerhills
4 Replies
9. Shell Programming and Scripting
I need to grep for the pattern text inside the square brackets which are in red and not in green..my current code greps patterns both of them, which i don't want
Input fileref|XP_002371341.1| oxoacyl-ACP reductase, putative gb|EPT24759.1| 3-ketoacyl-(acyl-carrier-protein) reductase ... (2 Replies)
Discussion started by: selvankj
2 Replies
10. Shell Programming and Scripting
The intended result should be :
PDF converters
'empty line'
gpdftext and pdftotext?xml version="1.0"?>
xml:space="preserve"><note-content version="0.1" xmlns:/tomboy/link" xmlns:size="http://beatniksoftware.com/tomboy/size">PDF converters
gpdftext and pdftotext</note-content>... (9 Replies)
Discussion started by: Klasform
9 Replies
border(3XCURSES) X/Open Curses Library Functions border(3XCURSES)
NAME
border, box, wborder - add a single-byte border to a window
SYNOPSIS
cc [ flag... ] file... -I /usr/xpg4/include -L /usr/xpg4/lib
-R /usr/xpg4/lib -lcurses [ library... ]
c89 [ flag... ] file... -lcurses [ library... ]
#include <curses.h>
int border(chtype ls, chtype rs, chtype ts, chtype bs, chtype tl, chtype tr, chtype bl, chtype br);
int wborder(WINDOW *win, chtype ls, chtype rs, chtype ts, chtype bs, chtype tl, chtype tr, chtype bl, chtype br);
int box(WINDOW *win, chtype verch, chtype horch);
DESCRIPTION
The border() and wborder() functions draw a border around the specified window. All parameters must be single-byte characters whose rendi-
tion can be expressed using only constants beginning with ACS_. A parameter with the value of 0 is replaced by the default value.
+--------------------------------------------------------------+
| Constant Values for Borders |
|Parameter Default Constant Default Character |
|verch ACS_VLINE | |
|horch ACS_HLINE - |
|ls ACS_VLINE | |
|rs ACS_VLINE | |
|ts ACS_HLINE - |
|bs ACS_HLINE - |
|bl ACS_BLCORNER + |
|br ACS_BRCORNER + |
|tl ACS_ULCORNER + |
|tr ACS_URCORNER + |
+--------------------------------------------------------------+
The call
box(win,
verch, horch)
is a short form for
wborder(win,
verch, verch,
horch, horch, 0, 0, 0,
0)
When the window is boxed, the bottom and top rows and right and left columns overwrite existing text.
PARAMETERS
ls Is the character and rendition used for the left side of the border.
rs Is the character and rendition used for the right side of the border.
ts Is the character and rendition used for the top of the border.
bs Is the character and rendition used for the bottom of the border.
tl Is the character and rendition used for the top-left corner of the border.
tr Is the character and rendition used for the top-right corner of the border.
bl Is the character and rendition used for the bottom-left corner of the border.
br Is the character and rendition used for the bottom-right corner of the border.
win Is the pointer to the window in which the border or box is to be drawn.
verch Is the character and rendition used for the left and right columns of the box.
horch Is the character and rendition used for the top and bottom rows of the box.
RETURN VALUES
On success, these functions return OK. Otherwise, they return ERR.
ERRORS
None.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Standard |
+-----------------------------+-----------------------------+
|MT-Level |Unsafe |
+-----------------------------+-----------------------------+
SEE ALSO
add_wch(3XCURSES), addch(3XCURSES), attr_get(3XCURSES), attroff(3XCURSES), border_set(3XCURSES), libcurses(3XCURSES), attributes(5), stan-
dards(5)
SunOS 5.10 5 Jun 2002 border(3XCURSES)