Sponsored Content
Top Forums Shell Programming and Scripting modifying specific lines a file Post 302339278 by ciba on Thursday 30th of July 2009 07:11:58 AM
Old 07-30-2009
the input file cannot be changed :Smilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Deleting specific lines in a file

I have a file which has some lines starting with a particular word. I would like to delete 5 lines before each such line containing that particular word. eg: line1 line2 line3 line4 line5 line6 "particular word"... I would like to delete line2-line6 and all such occurences in that... (4 Replies)
Discussion started by: ramu_1980
4 Replies

2. UNIX for Dummies Questions & Answers

How do you specific lines in a file?

I'm looking to show specific lines (eg. 20 through 40) of a series of files in the directory. How do I do this? (2 Replies)
Discussion started by: hedgehog001
2 Replies

3. UNIX for Dummies Questions & Answers

Displaying specific lines in a file.

I'm trying to figure out how to display a certain line in a text file. I keep getting references to Tail and Head, and I know how these work, but i'm lost on how to find say the third out of the five lines and display only that. I thought maybe grep could help, but that doesn't seem likely. ... (3 Replies)
Discussion started by: MaestroRage
3 Replies

4. UNIX for Dummies Questions & Answers

how to display specific lines of a specific file

are there any basic commands that can display lines 99 - 101 of the /etc/passwd file? I'm thinking use of head and tail, but I forget what numbers to use and where to put /etc/passwd in the command. (2 Replies)
Discussion started by: raidkridley
2 Replies

5. Shell Programming and Scripting

Substitute specific lines with lines from another file

Hello All, I am new to this forum. I am currently facing a problem in manipulating files. I have two files called old-matter and new-matter # cat old-matter abc: this, is a, sample, entry byi: white board, is white in color rtz: black, board is black qty: i tried, a lot asd: no... (1 Reply)
Discussion started by: rahmathulla
1 Replies

6. Shell Programming and Scripting

awk modifying entries on 2 lines at 2 positions

Hi this script adds text in the correct place on one line only, in a script. awk 'BEGIN{ printf "Enter residue and chain information: " getline var < "-" split(var,a) } /-s rec:/{$7=a; } {print}' FLXDOCK but I need the same info added at position 7 on line 34 and... (1 Reply)
Discussion started by: gav2251
1 Replies

7. Solaris

Setting/Modifying variable specific to target in Makefile

Hi, I have a small piece of Makefile script which throw's error on Sun Sparc machine, but works fine with Sun Optron, Linux, AIX machines. FOO=Naveen test1:FOO=Dhilip test1: @echo FOO is ${FOO} test2: @echo Me is ${FOO} Output on Sun Sparc - ukhml-v890new-~/test: make test1... (5 Replies)
Discussion started by: nsriram
5 Replies

8. Shell Programming and Scripting

Extracting specific lines of data from a file and related lines of data based on a grep value range?

Hi, I have one file, say file 1, that has data like below where 19900107 is the date, 19900107 12 144 129 0.7380047 19900108 12 168 129 0.3149017 19900109 12 192 129 3.2766666E-02 ... (3 Replies)
Discussion started by: Wynner
3 Replies

9. UNIX for Dummies Questions & Answers

Quick UNIX command to display specific lines in the middle of a file from/to specific word

This could be a really dummy question. I have a log text file. What unix command to extract line from specific string to another specific string. Is it something similar to?: more +/"string" file_name Thanks (4 Replies)
Discussion started by: aku
4 Replies

10. UNIX for Dummies Questions & Answers

Add strings from one file at the end of specific lines in text file

Hello All, this is my first post so I don't know if I am doing this right. I would like to append entries from a series of strings (contained in a text file) consecutively at the end of specifically labeled lines in another file. As an example: - the file that contains the values to be... (3 Replies)
Discussion started by: gus74
3 Replies
XSupportsLocale(3)						  XLIB FUNCTIONS						XSupportsLocale(3)

NAME
XSupportsLocale, XSetLocaleModifiers - determine locale support and configure locale modifiers SYNTAX
Bool XSupportsLocale(void); char *XSetLocaleModifiers(char *modifier_list); ARGUMENTS
modifier_list Specifies the modifiers. DESCRIPTION
The XSupportsLocale function returns True if Xlib functions are capable of operating under the current locale. If it returns False, Xlib locale-dependent functions for which the XLocaleNotSupported return status is defined will return XLocaleNotSupported. Other Xlib locale- dependent routines will operate in the ``C'' locale. The XSetLocaleModifiers function sets the X modifiers for the current locale setting. The modifier_list argument is a null-terminated string of the form ``{@category=value}'', that is, having zero or more concatenated ``@category=value'' entries, where category is a cate- gory name and value is the (possibly empty) setting for that category. The values are encoded in the current locale. Category names are restricted to the POSIX Portable Filename Character Set. The local host X locale modifiers announcer (on POSIX-compliant systems, the XMODIFIERS environment variable) is appended to the modi- fier_list to provide default values on the local host. If a given category appears more than once in the list, the first setting in the list is used. If a given category is not included in the full modifier list, the category is set to an implementation-dependent default for the current locale. An empty value for a category explicitly specifies the implementation-dependent default. If the function is successful, it returns a pointer to a string. The contents of the string are such that a subsequent call with that string (in the same locale) will restore the modifiers to the same settings. If modifier_list is a NULL pointer, XSetLocaleModifiers also returns a pointer to such a string, and the current locale modifiers are not changed. If invalid values are given for one or more modifier categories supported by the locale, a NULL pointer is returned, and none of the cur- rent modifiers are changed. At program startup, the modifiers that are in effect are unspecified until the first successful call to set them. Whenever the locale is changed, the modifiers that are in effect become unspecified until the next successful call to set them. Clients should always call XSet- LocaleModifiers with a non-NULL modifier_list after setting the locale before they call any locale-dependent Xlib routine. The only standard modifier category currently defined is ``im'', which identifies the desired input method. The values for input method are not standardized. A single locale may use multiple input methods, switching input method under user control. The modifier may specify the initial input method in effect or an ordered list of input methods. Multiple input methods may be specified in a single im value string in an implementation-dependent manner. The returned modifiers string is owned by Xlib and should not be modified or freed by the client. It may be freed by Xlib after the cur- rent locale or modifiers are changed. Until freed, it will not be modified by Xlib. SEE ALSO
Xlib - C Language X Interface X Version 11 libX11 1.5.0 XSupportsLocale(3)
All times are GMT -4. The time now is 09:35 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy