02-24-2009
A phrase is a collection of n number of words that are the same. Could be anything from 2 to n. So for example in a sample text:
The quick brown fox jumped over the ugly dog
The quick brown fox is fast asleep in a corner.
In the above sample 'The quick brown fox' is a the phrase I am looking for, as it occurs twice in the text. In another sample
My name is John Doe
My name used to Alfred
The "phrase" here will be "My name" as that is what is consistent.
I hope that makes a bit more sense ?
Thanks
SG
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Dear All,
To find the length of the longest line from a file i have used wc -L which is giving the proper output...
But the problem is AIX os does not support wc -L command.
so is there any other way 2 to find out the length of the longest line using awk or sed ?
Regards,
Pankaj (1 Reply)
Discussion started by: panknil
1 Replies
2. Shell Programming and Scripting
Okie here is my problem,
1. I have a directory with a ton of files.
2. I want to first get an input on how many days ago the files were created.
3. I will take those files and put it into another file
4. Then I will take the last # from each line and subtract by 1 then diff the line from the... (1 Reply)
Discussion started by: bigboizvince
1 Replies
3. Shell Programming and Scripting
I've got a script which finds *.txt files in directories and subdirectories after providing the path by the user and then searches in the files for phrase given by the user
How to write script in such way that the paths to the found *.txt files and the phrase given by the user were both... (2 Replies)
Discussion started by: patrykxes
2 Replies
4. Shell Programming and Scripting
Return the position of matched string from right, awk match can do from left only.
e.g return pos 7 for search string "service" from "AA-service"
or return the matched string "service", then caculate the string length.
Thanks!. (3 Replies)
Discussion started by: honglus
3 Replies
5. Shell Programming and Scripting
Hello everyone...
I need to find out, how to find longest line or possibly lines in several files which are arguments for script. The thing is, that I tried some possibilities before, but nothing worked correctly.
Example
when i use:
awk ' { if ( length > L ) { L=length ;s=$0 } }END{ print... (23 Replies)
Discussion started by: 1tempus1
23 Replies
6. Shell Programming and Scripting
Hello all,
I need to find the longest string in a select field and print that field.
I have tried a few different methods and I always end up one step from where I need to be.
Methods thus far:
nawk '{if (length($1) > long) long=length($1); if(length($1)==long) print $1}'
The above... (6 Replies)
Discussion started by: SEinT
6 Replies
7. Shell Programming and Scripting
Hello
My question is: How to find out the shell of the shell script which we are running? I am writing a script, say f1.sh, as below:
#!/bin/ksh
echo "Sample script"
From the first line, we can say this script will run in ksh. But, how can we prove it? Can we print anything inside... (6 Replies)
Discussion started by: guruprasadpr
6 Replies
8. Shell Programming and Scripting
I want to make a script which takes the number of argument, add those argument and gives output to the user, but I am not getting through...
Script that i am using is below :
#!/bin/bash
sum=0
for i in $@
do
sum=$sum+$1
echo $sum
shift
done
I am executing the script as... (3 Replies)
Discussion started by: mukulverma2408
3 Replies
9. Shell Programming and Scripting
I want to burst a report by using the page number value in the report header. Each section starts with *PAGE NO:* 1 Each section might have several pages, but the next section always starts back at 1.
So I want to find the "*PAGE NO:* 1" value and pull all lines that follow until "*PAGE NO:* 1"... (4 Replies)
Discussion started by: Scottie1954
4 Replies
10. Shell Programming and Scripting
Hello,
I am looking for a shell script that can
1- take as input a variable, like "server.cpu"
2- do a search for that variable in a directory that contains subdirectories.
The search will start at the last subdirectory working up to the top level if I can not find the file
3-... (7 Replies)
Discussion started by: georg2014
7 Replies
LEARN ABOUT DEBIAN
grid-change-pass-phrase
GRID-CHANGE-PASS-(1) Globus Commands GRID-CHANGE-PASS-(1)
NAME
grid-change-pass-phrase - Change the passphrase of a private key
SYNOPSIS
grid-change-pass-phrase [-help] [-usage] [-version] [-versions]
grid-change-pass-phrase [-file PRIVATE-KEY]
DESCRIPTION
The grid-change-pass-phrase program changes the passphrase protecting a private key or PKCS12 bundle containing a private key and
certificate. By default, grid-change-pass-phrase uses the X509_USER_KEY environment variable to locate the private key. If that is not set,
then it looks for $HOME/.globus/userkey.pem and $HOME/.globus/usercred.p12 in succession. The path to a key can be specified by using the
-file command-line option.
The full set of command-line options to grid-change-pass-phrase are:
-help, -usage
Display the command-line options to grid-change-pass-phrase and exit.
-version, -versions
Display the version number of the grid-change-pass-phrase command. The second form includes more details.
-file PRIVATE-KEY
Change the passphrase of the private key named by PRIVATE-KEY instead of the default.
EXAMPLES
Change the passphrase of the default private key:
% grid-change-pass-phrase
Enter pass phrase for /home/juser/.globus/userkey.pem:
writing RSA key
Enter PEM pass phrase:
Verifying - Enter PEM pass phrase:
ENVIRONMENT VARIABLES
The following environment variables affect the execution of grid-change-pass-phrase:
X509_USER_KEY
Path to the default private key file.
AUTHOR
University of Chicago
Globus Toolkit 5.0.1 03/22/2010 GRID-CHANGE-PASS-(1)