08-13-2009
Regex NOT EQUAL help
I have the following line to text:
ExecuteQueue Name=default ThreadCount=60
I want to write a sed or awk function that eliminates everything before "ThreadCount" without taking into account what is actually in front of ThreadCount. Meaning there may be text in front of "ThreadCount" other than what is currently in front of it now. Basically I am looking for a delete everything NOT EQUAL to <STRING> and I cant seem to find anything like that in any sed documentation.
9 More Discussions You Might Find Interesting
1. Solaris
Hi,
I have replaced my current Intel PC machine with Solaris 10, it use to have windows XP.
I am sure alot of people already done this and i have seen Solaris running smoothly but having keyboard problem.
What is the equal keys in a QWERTY keyboard for selection <Stop+A> ?
Is there a... (5 Replies)
Discussion started by: tlee
5 Replies
2. Shell Programming and Scripting
Hi,
I have the below script executed
arg="dir"
if "$arg" = "dir"
then
echo "true"
else
echo "false"
fi
Please let me know what happens in the if command.
My output is:
dir: dir: No such file or directory
false
which is not the desired output.
When i used test command... (1 Reply)
Discussion started by: anijan
1 Replies
3. Shell Programming and Scripting
Does anybody understand why this is not being interpreted as true.
Script:
#!/bin/bash
errored=`grep "errored" new_update_scripts.txt`
echo $errored = "errored"
if ; then
echo true
else
echo false
fi
Output:
$ UpdateScripts
errored = errored
false (7 Replies)
Discussion started by: scottwmackey
7 Replies
4. Shell Programming and Scripting
while + and equal to zero ; then
what to punt instead of phrase and equal to zero.
it's bash
thank you in advance (1 Reply)
Discussion started by: losh
1 Replies
5. Shell Programming and Scripting
I am having trouble parsing rpm filenames in a shell script.. I found a snippet of perl code that will perform the task but I really don't have time to rewrite the entire script in perl. I cannot for the life of me convert this code into something sed-friendly:
if ($rpm =~ /(*)-(*)-(*)\.(.*)/)... (1 Reply)
Discussion started by: suntzu
1 Replies
6. UNIX for Dummies Questions & Answers
I have a file of protein sequences with headers (my source file). Based on a list of IDs (which are included in some of the headers), I'd like to print out only the specified sequences, with only the ID as header.
In other words, I'd like to search source.txt for the terms in IDs.txt, and print... (3 Replies)
Discussion started by: pathunkathunk
3 Replies
7. Shell Programming and Scripting
I am not a big expert in regex and have just little understanding of that language.
Could you help me to understand the regular Perl expression:
^(?!if\b|else\b|while\b|)(?:+?\s+){1,6}(+\s*)\(*\) *?(?:^*;?+){0,10}\{
------
This is regex to select functions from a C/C++ source and defined in... (2 Replies)
Discussion started by: alex_5161
2 Replies
8. Shell Programming and Scripting
I'm trying to get some exclusions into our sendmail regular expression for the K command. The following configuration & regex works:
LOCAL_CONFIG
#
Kcheckaddress regex -a@MATCH
+<@+?\.++?\.(us|info|to|br|bid|cn|ru)
LOCAL_RULESETS
SLocal_check_mail
# check address against various regex... (0 Replies)
Discussion started by: RobbieTheK
0 Replies
9. UNIX for Advanced & Expert Users
Did I do something wrong with this awk not equal? For some reason it prints twice.
>awk '{if ($4 != "root") print $1 " " $4 " " $5}' ls_test
server10: njs nodeadm
server10: njs nodeadm
>grep server10 ls_test
server10: drwxr-sr-x. 18 njs nodeadm 4096 Aug 16 09:42 /opt
> (2 Replies)
Discussion started by: cokedude
2 Replies
LEARN ABOUT REDHAT
glfrontface
GLFRONTFACE(3G) GLFRONTFACE(3G)
NAME
glFrontFace - define front- and back-facing polygons
C SPECIFICATION
void glFrontFace( GLenum mode )
PARAMETERS
mode Specifies the orientation of front-facing polygons. GL_CW and GL_CCW are accepted. The initial value is GL_CCW.
DESCRIPTION
In a scene composed entirely of opaque closed surfaces, back-facing polygons are never visible. Eliminating these invisible polygons has
the obvious benefit of speeding up the rendering of the image. To enable and disable elimination of back-facing polygons, call glEnable
and glDisable with argument GL_CULL_FACE.
The projection of a polygon to window coordinates is said to have clockwise winding if an imaginary object following the path from its
first vertex, its second vertex, and so on, to its last vertex, and finally back to its first vertex, moves in a clockwise direction about
the interior of the polygon. The polygon's winding is said to be counterclockwise if the imaginary object following the same path moves in
a counterclockwise direction about the interior of the polygon. glFrontFace specifies whether polygons with clockwise winding in window
coordinates, or counterclockwise winding in window coordinates, are taken to be front-facing. Passing GL_CCW to mode selects counterclock-
wise polygons as front-facing; GL_CW selects clockwise polygons as front-facing. By default, counterclockwise polygons are taken to be
front-facing.
ERRORS
GL_INVALID_ENUM is generated if mode is not an accepted value.
GL_INVALID_OPERATION is generated if glFrontFace is executed between the execution of glBegin and the corresponding execution of glEnd.
ASSOCIATED GETS
glGet with argument GL_FRONT_FACE
SEE ALSO
glCullFace(3G), glLightModel(3G)
GLFRONTFACE(3G)