Sponsored Content
Full Discussion: Search Character
Top Forums Shell Programming and Scripting Search Character Post 302469294 by Corona688 on Friday 5th of November 2010 11:07:39 AM
Old 11-05-2010
And that doesn't? It looks like it does to me.
Code:
$ echo 'stuff asdf <tag> <tag param="BP1418">' > file.xml
$ egrep -o '"BP[0-9]+'" file.xml
"BP1418"
$

If that's not what you wanted, please explain more clearly.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Search for a non zero character in file

Hi, I have a log file which has entries as Staged 0 records from fn.dat (0 failed) 01/01 01:01:01 I 0 Error Transactions I want to find out any line that has an entry like "(1 failed)" or "(2 failed)" or any number in general ( >0 ) similarly it should search for string like "1... (4 Replies)
Discussion started by: misenkiser
4 Replies

2. Shell Programming and Scripting

Search in variable for character

qwertyuioplkjhgfdsa (1 Reply)
Discussion started by: rorey_breaker
1 Replies

3. UNIX for Dummies Questions & Answers

to search for a particular character in a word

Hi I would like to accept in a string from user like username/pwd@dbname suppose the user does not input @ then i should throw an error that @ symbol missing . How to achieve this Thanks in advance Suresh (6 Replies)
Discussion started by: ssuresh1999
6 Replies

4. Shell Programming and Scripting

Need to search and replace based on character count

Hi, I wanted to add a newline character after every 100 characters in a file using a awk or shell without reading each line of the file. I want to run a command on the complete file. This does based on a string but i want to add a new line after every 100 characters ir-respective of the... (3 Replies)
Discussion started by: vijaykrc
3 Replies

5. UNIX for Dummies Questions & Answers

global search and replacement of a non-ascii character

Hi, I need to do a global search and replacement of a non-ascii character. Let me first give the background of my problem. Very frequently, I need to copy set of references from different sources. Typically, a reference would like this: Banumathy et al., 2002 G. Banumathy, V. Singh and U.... (1 Reply)
Discussion started by: effjay
1 Replies

6. UNIX for Dummies Questions & Answers

how to search and list file with wildcard character

hi, I want to search all files in the current working direcotry and to print in comma (,) seperated output. But I have two patterns to search for. Files will be in ABC20100508.DAT format. Search should happen on the format (ABC????????.DAT) along with date(20100508). I can do a ls... (2 Replies)
Discussion started by: anandapani
2 Replies

7. Shell Programming and Scripting

awk search for space character

How do I use awk to search for a string that contains a space bar? I have tried this awk '/send email/ {print $0}' input awk '/send\ email/ {print $0}' input (1 Reply)
Discussion started by: locoroco
1 Replies

8. Shell Programming and Scripting

Ls help: ls not working with start character search (^)

Experts, How to list a file using ^ character, for all files started with character a. (os= hp-ux ) # ls -l -rw------- 1 useradm users 0 Mar 26 14:30 abc -rw------- 1 useradm users 0 Mar 26 14:30 def -rw------- 1 useradm users 0 Mar 26... (7 Replies)
Discussion started by: rveri
7 Replies

9. UNIX for Dummies Questions & Answers

Search for a particular word and replace the first character

Hi Unix gurus, I've a dna sequence in a file format known as fasta format (sequence header starts with > and ignored), an example shown below: >sequence_1 CGTATTCTCCGAATACC ATACG >sequence_2 CAGATTTTCAAATACCCCC In a file like this I want to do the following three search and replace. The... (4 Replies)
Discussion started by: Fahmida
4 Replies

10. Shell Programming and Scripting

Search a character and replace it with multiple lines

This is for AIX 6.1, I've a flat file and the format is like this DECLARE some statements; BEGIN some statements; END; I've to search BEGIN and replace it with the following 4 lines BEGIN For x in 1..1 LOOP BEGIN Similarly I've to search END and replace it with the... (7 Replies)
Discussion started by: Mukul Sharma
7 Replies
KEXTLIBS(8)						    BSD System Manager's Manual 					       KEXTLIBS(8)

NAME
kextlibs -- find OSBundleLibraries needed by a kext SYNOPSIS
kextlibs [options] [--] kext ... DESCRIPTION
The kextlibs utility searches for library kexts that define symbols needed for linking by kext, printing their bundle identifiers and ver- sions to stdout. If the kext has a multiple-architecture executable, libraries are resolved for each architecture. If any symbols are not found, or are found in multiple libraries, the numbers of such symbols are printed to standard error after the library kext information for each architecture. A handy use of kextlibs is to run it with just the -xml flag and pipe the output to pbcopy(1); if the exit status is zero (indicating no undefined or multiply-defined symbols), you can open your kext's Info.plist file in a text editor and paste the library declarations over the OSBundleLibraries property. You can use kextlibs to find libraries for older releases of Mac OS X using the -repository option to specify an extensions folder to search other than the extensions directories for the root volume (although releases prior to Mac OS X 10.6 (Snow Leopard) don't check for architec- ture-specific properties, so be sure to check the output and edit as needed). If you don't explicitly specify a repository directory, kextlibs searches the root volume's /System/Library/Extensions and /Library/Extensions directories. OPTIONS
-h, -help Print a help message describing each option flag and exit with a success result, regardless of any other options on the command line. -all-symbols Print reports on all symbols that remain undefined, all symbols that have been resolved in one library kext each, and all symbols that have multiple definitions in different library kexts. Equivalent to specifying all of -undef-symbols, -onedef-symbols, and -multdef-symbols. Normally only the number of missing and duplicate symbols is printed. -c, -compatible-versions Print the compatible version rather than the current version. -multdef-symbols Print all undefined symbols from kext found in more than one library kext, followed by those library kexts' bundle identifiers and versions (or compatible versions if -compatible-versions was specified). Normally only the number of multiply-defined symbols is printed. -non-kpi Search the compatibility kext, com.apple.kernel.6.0, rather than any of the com.apple.kpi.* system kexts. Use of this option is not recommended: The exact kernel component (mach, bsd, libkern, or iokit) cannot be determined, and the compatible version of com.apple.kernel is locked to its current version, so kexts linking against it can only load against that exact version. -onedef-symbols Print all undefined symbols from kext found in exactly one library kext, followed by that library kext's bundle identifier and ver- sion (or compatible version if -compatible-versions was specified). Normally nothing is printed about symbols that are found once. -r directory, -repository directory Search directory for dependencies. This option may be specified multiple times. You can use this to get library declarations rela- tive to a set of extensions other than those of the running system (such as for a different release of Mac OS X), or to include a side directory of library kexts. Note: If you specify a directory with this option, the system extensions folders are not implic- itly searched. See -system-extensions. -e, -system-extensions Add /System/Library/Extensions and /Library/Extensions to the list of directories to search. If you don't specify any directories or kexts, this is used by default. -undef-symbols Print all undefined symbols from kext that can't be found in any library kexts. Normally only the number of symbols not found is printed. -unsupported Search unsupported library kexts for symbols (by default they are not searched). -v [0-6 | 0x####], -verbose [0-6 | 0x####] Verbose mode; print information about program operation. Higher levels of verbosity include all lower levels. You can specify a level from 0-6, or a hexadecimal log specification (as described in kext_logging(8)). For kextlibs, the decimal levels 1-6 generally have little effect. -xml Print an XML fragment to stdout suitable for copying and pasting directly into an Info.plist file. This option prints information about libraries to stdout, and then prints information about symbols to stderr. In XML mode, if the libraries for all architectures are the same, only one set of OSBundleLibraries is printed; if any differ from any others, architecture-specific listings for all architectures are printed (OSBundleLibraries_i386, OSBundleLibraries_x86_64, and so on). -- End of options. FILES
/System/Library/Extensions/ The standard system repository of kernel extensions. /Library/Extensions/ The standard repository of non Apple kernel extensions. DIAGNOSTICS
The kextlibs utility exits with a status of 0 on completion if all undefined symbols are found exactly once; with a status of 1 if any unde- fined symbols remain, or with a status of 2 if any symbols are found in more than one library kext (whether or not any undefined symbols remain), and with another nonzero status on some other problem. BUGS
kextlibs uses a simple algorithm of string matching to resolve symbols, and does not apply any of the patching that the full link process does. This can cause it to fail when searching for symbols in a kext built against an SDK for a prior release of Mac OS X than the one on which kextlibs is being used. In such cases, you can run kextlibs against the Extensions folder of that prior release using the -repository option. Many single-letter options are inconsistent in meaning with (or directly contradictory to) the same letter options in other kext tools. SEE ALSO
kextutil(8), kextfind(8), kext_logging(8) Darwin November 14, 2012 Darwin
All times are GMT -4. The time now is 10:10 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy