Sponsored Content
Top Forums Shell Programming and Scripting Using key words or symbols to determine parser Post 302938722 by cmccabe on Wednesday 18th of March 2015 02:25:36 PM
Old 03-18-2015
To specify the filename, though I am not sure. DEL_position.txt is the file containing the "del" in it. Thank you Smilie

Code:
  awk 'FNR==1 {next} match($1,/\.[0-9]+del[ACGT]+/) {print "del: ", FILENAME, substr($1, RSTART+RLENGTH-1)} /\.[0-9]+[ACGT]+>[ACGT]+/ {print ">: ",FILENAME}' DEL_position.txt[34]>:  file3 del:  file4 G

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

deleting symbols and characters between two words

Hi Please tell me how could i delete symbols, whitespaces, characters, words everything between two words in a line. Let my file is aaa BB ccc ddd eee FF kkk xxx 123456 BB 44^& iop FF 999 xxx uuu rrr BB hhh nnn FF 000 I want to delete everything comes in between BB and FF( deletion... (3 Replies)
Discussion started by: rish_max
3 Replies

2. Shell Programming and Scripting

removing the words with symbols in a file in unix

I have file like below Hi iam author <br>joseph</br> in france. I live in my home <br></br> but no food. I will play footbal <br></br> but i wont play cricket. I will read all the books <br>all fiction stories</br> i hate horror stories. I want output like below Hi iam author... (3 Replies)
Discussion started by: vinothsekark
3 Replies

3. Shell Programming and Scripting

grep - Extracting multiple key words from stdout

Hello. From command line, the command zypper info nxclient return a bloc of data : linux local # zypper info nxclient Loading repository data... Reading installed packages... Information for package nxclient: Repository: zypper_local Name: nxclient Version: 3.5.0-7 Arch: x86_64... (7 Replies)
Discussion started by: jcdole
7 Replies

4. Shell Programming and Scripting

Extract key words and print their values

Input file (HTTP request log file): GET... (2 Replies)
Discussion started by: buptwy
2 Replies

5. UNIX for Dummies Questions & Answers

Filter logs for key words and create an index

well, im a total novice of unix commands and shell scripting, i never made anything. But yesterday in my work i was working with a lot of log files and i was wondering if there is a command for doing something like this: i have a bunch of files with text like this: blablabla errorcode1... (11 Replies)
Discussion started by: matius_88
11 Replies

6. UNIX for Dummies Questions & Answers

Delete lines according to a key words in that line

HI, I have a file A like this: c 1 length 14432 width 3434 temp 34 c 2 length 3343 width 0923 height 9383 hm 902 temp34 c 3 length 938 height 982 hm 9292 temp 23 ... (2 Replies)
Discussion started by: the_simpsons
2 Replies

7. UNIX for Beginners Questions & Answers

Non-root script used search and list specific key words

Hy there all. Im new here. Olso new to terminal & bash, but it seams that for me it's much easyer to undarsatnd scripts than an actual programming language as c or anyother languare for that matter. S-o here is one og my home works s-o to speak. Write a shell script which: -only works as a... (1 Reply)
Discussion started by: Crisso2Face
1 Replies

8. Shell Programming and Scripting

Delete lines containing key words dynamically

Hi Frens, I have a requirement where I need to delete lines having key words and am using the below command to do that sed '/UNIX/d' inputfile > output But now I have one more requirement where in there will be one reference file which has the ID's to be deleted from the master file. ... (3 Replies)
Discussion started by: weknowd
3 Replies

9. Shell Programming and Scripting

sed parser behaving strange on replacing multiple words in multiple files

I have 4000 files like $cat clus_grp_seq10_g.phy 18 1002 anig_OJJ65951_1 ATGGTTTCGCAGCGTGATAGAGAATTGTTTAGGGATGATATTCGCTCGCGAGGAACGAAGCTCAATGCTGCCGAGCGCGAGAGTCTGCTAAGGCCATATCTGCCAGATCCGTCTGACCTTCCACGCAGGCCACTTCAGCGGCGCAAGAAGGTTCCTCG aver_OOF92921_1 ... (1 Reply)
Discussion started by: sammy777888
1 Replies

10. Red Hat

How to block some key words in my url for apache config?

Hi Folks, I am running a website and that needs to be tightened with security in terms of hacking... Whereas, In my URL, when i click on certain links the entire link as contains some words like below:/control_panel /controlpanel /admin /cms Whereas, i need to block those words in apache... (1 Reply)
Discussion started by: gsiva
1 Replies
XMLCATALOG(1)							 xmlcatalog Manual						     XMLCATALOG(1)

NAME
xmlcatalog - Command line tool to parse and manipulate XML or SGML catalog files. SYNOPSIS
xmlcatalog [--sgml | --shell | --create | --del VALUE(S) | [ --add TYPE ORIG REPLACE | --add FILENAME] | --noout | --no-super-update | [-v | --verbose]] {CATALOGFILE} {ENTITIES...} DESCRIPTION
xmlcatalog is a command line application allowing users to monitor and manipulate XML and SGML catalogs. It is included in libxml(3). Its functions can be invoked from a single command from the command line, or it can perform multiple functions in interactive mode. It can operate on both XML and SGML files. OPTIONS
xmlcatalog accepts the following options (in alphabetical order): --add TYPE ORIG REPLACE Add an entry to CATALOGFILE. TYPE indicates the type of entry. Possible types are: public, system, uri, rewriteSystem, rewriteURI, delegatePublic, delegateSystem, delegateURI, nextCatalog. ORIG is the original reference to be replaced, and REPLACE is the URI of the replacement entity to be used. The --add option will not overwrite CATALOGFILE, outputting to stdout, unless --noout is used. The --add will always take three parameters even if some of the XML catalog constructs will have only a single argument. --add FILENAME If the --add option is used following the --sgml option, only a single argument, a FILENAME, is used. This is used to add the name of a catalog file to an SGML supercatalog, a file that contains references to other included SGML catalog files. --create Create a new XML catalog. Outputs to stdout, ignoring filename unless --noout is used, in which case it creates a new catalog file filename. --del VALUE(S) Remove entries from CATALOGFILE matching VALUE(S). The --del option will not overwrite CATALOGFILE, outputting to stdout, unless --noout is used. --noout Save output to the named file rather than outputting to stdout. --no-super-update Do not update the SGML super catalog. --shell Run a shell allowing interactive queries on catalog file CATALOGFILE. For the set of available commands see the section called "SHELL COMMANDS". --sgml Uses SGML super catalogs for --add and --del options. -v, --verbose Output debugging information. SHELL COMMANDS
Invoking xmlcatalog with the --shell CATALOGFILE option opens a command line shell allowing interactive access to the catalog file identified by CATALOGFILE. Invoking the shell provides a command line prompt after which the following commands (described in alphabetical order) can be entered. add TYPE ORIG REPLACE Add an entry to the catalog file. TYPE indicates the type of entry. Possible types are: public, system, uri, rewriteSystem, rewriteURI, delegatePublic, delegateSystem, delegateURI, nextCatalog. ORIG is the original reference to be replaced, and REPLACE is the URI of the replacement entity to be used. The --add option will not overwrite CATALOGFILE, outputting to stdout, unless --noout is used. The --add will always take three parameters even if some of the XML catalog constructs will have only a single argument. debug Print debugging statements showing the steps xmlcatalog is executing. del VALUE(S) Remove the catalog entry corresponding to VALUE(S). dump Print the current catalog. exit Quit the shell. public PUBLIC-ID Execute a Formal Public Identifier look-up of the catalog entry for PUBLIC-ID. The corresponding entry will be output to the command line. quiet Stop printing debugging statements. system SYSTEM-ID Execute a Formal Public Identifier look-up of the catalog entry for SYSTEM-ID. The corresponding entry will be output to the command line. ENVIRONMENT
XML_CATALOG_FILES XML catalog behavior can be changed by redirecting queries to the user's own set of catalogs. This can be done by setting the XML_CATALOG_FILES environment variable to a list of catalogs. An empty one should deactivate loading the default /etc/xml/catalog catalog. DIAGNOSTICS
xmlcatalog return codes provide information that can be used when calling it from scripts. 0 No error 1 Failed to remove an entry from the catalog 2 Failed to save to the catalog, check file permissions 3 Failed to add an entry to the catalog 4 Failed to look up an entry in the catalog SEE ALSO
libxml(3) More information can be found at o libxml(3) web page http://www.xmlsoft.org/ o libxml(3) catalog support web page at http://www.xmlsoft.org/catalog.html o James Clark's SGML catalog page http://www.jclark.com/sp/catalog.htm o OASIS XML catalog specification http://www.oasis-open.org/committees/entity/spec.html AUTHOR
John Fleck <jfleck@inkstain.net> Author. COPYRIGHT
Copyright (C) 2001, 2004 libxml2 $Date$ XMLCATALOG(1)
All times are GMT -4. The time now is 04:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy