01-16-2010
Quote:
Originally Posted by
gaurav1086
Personally, I think the preprocessor option fits the bill perfectly.
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
11132
13069
11137
11142
13070
Can I use grep command to exclude all lines beginning with 13?
I dont want to use grep -v 13 as potentially there will be a number with something like 11013 that I would exclude in error.. (2 Replies)
Discussion started by: frustrated1
2 Replies
2. UNIX for Advanced & Expert Users
I am doing "ps -f" to see my process.
but I get lines that one of it represents the ps command itself.
I want to grep it out using -v flag, but than I get another process that belongs to the GREP itself :
I would like to exclude
# ps -f
UID PID PPID C STIME TTY TIME CMD... (2 Replies)
Discussion started by: yamsin789
2 Replies
3. UNIX for Dummies Questions & Answers
Hello, I'm trying to use grep or egrep to exclude a whole range of characters but how do I exclude both a single and a double quote.
It might be easier to say how do I use grep to find both single and double quotes.
grep ' ' " ' file
grep detects the first single quote within my... (4 Replies)
Discussion started by: Lindy_so
4 Replies
4. Shell Programming and Scripting
I must write a script to change all C++ like comments:
// this is a comment
to this one
/* this is a comment */
How to do it by sed? With file:
#include <cstdio>
using namespace std; //one
// two
int main() {
printf("Example"); // three
}//four
the result should be: (2 Replies)
Discussion started by: black_hawk
2 Replies
5. Shell Programming and Scripting
I wrote this korn script and ran into a hole. I can use find to exclude all the hidden directories and to use my include file/exclude files for running a full backup
find / -depth -ipath '/home/testuser/.*' -prune -o -print| grep -f include.mydirs | grep -v -f exclude.mydirs
but when I... (8 Replies)
Discussion started by: metallica1973
8 Replies
6. Shell Programming and Scripting
Hi,
Below is the command to grep for a string under
grep -r "redeem" /home/tom
Need to make it case insensitive and exclude logs & tmp folders under /home/tom directory in my Search.
Need this in Linux. (1 Reply)
Discussion started by: mohtashims
1 Replies
7. Shell Programming and Scripting
Hi,
I must be overlooking something, but I don't understand why this doesn't work. I'm trying to grep on a date, excluding all the lines starting with a dash:
testfile:
#2013-12-31
2013-12-31code:
grep '^2013-12-31' testfileI'm expecting to see just the second line '2013-12-31' but I don't... (3 Replies)
Discussion started by: Subbeh
3 Replies
8. Shell Programming and Scripting
.......
06/09/2013|12:00:00 PM|3|26112|40|44032|27419.7|6 1 0 93 |6|1|0|93
06/09/2013|12:30:00 PM|3|26112|40|44032|27491|11 4 0 85 |11|4|0|85
I have "sysperf.out" file containing the lines above.
What I like to have on the output is:
Node: prod1db ===> this is the hostname
Date:... (7 Replies)
Discussion started by: Daniel Gate
7 Replies
9. Shell Programming and Scripting
Hi,
I'm working on a shell script that reports service status on a database server.
There are some services that are in disabled status that the script should ignore and only check the services that are in Enabled status.
I output the service configuration to a file and use that information to... (5 Replies)
Discussion started by: senthil3d
5 Replies
ocs(1) General Commands Manual ocs(1)
NAME
ocs - creates and maintains the database for cscope on a recursive directory set
SYNOPSIS
ocs [-x] [-f] [-q] [-u]
DESCRIPTION
This manual page briefly documents ocs , a shell script wrapper that automates the creation and maintenance of a cscope(1) database on a
recursive set of directories. Under normal circumstances, ocs generates a cscope database on a recursive group of directories starting from
the current working directory, before launching cscope(1) in interactive mode.
OPTIONS
-x Enable debugging.
-f Force. Do not ask about regenerating 'TMP' lists (lists generated by ocs ), just do it; Allow the regeneration of 'CSD' (lists gen-
erated by cscope(1) ) lists.
-q Tell cscope to build a fast reverse index. Database disk space usage is doubled, but searching speed is increased.
-u Request that the database be updated or regenerated.
FILES
./cscope.rc
If this is an executable shell script, it will be included in the body of ocs in order to override intenal filenames and other
options. See the comments at the top of /usr/bin/ocs for more information.
BUGS
None noted.
SEE ALSO
cscope(1), /usr/bin/ocs.
AUTHORS
This manpage originally prepared by Nick Rusnov <nick@grawk.net> for the Debian Project.
The Debian Project June 2001 ocs(1)