Sponsored Content
Full Discussion: Reverse *
Top Forums Shell Programming and Scripting Reverse * Post 70137 by vgersh99 on Tuesday 26th of April 2005 07:40:03 AM
Old 04-26-2005
Quote:
Originally Posted by azmathshaikh
when I do
$ ls z*
List of all files begining with 'z'. But what if I want to do a reverse lookup. Just for interest sake Smilie
$ ls ztr
should be same as
$ ls ztr*
$ ls zt*
$ ls z*
for listing files NOT begining with a 'z':
ls [!z]*
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Reverse Display

I need to display a line in an xterm window but i want to revese the colors so that the background color becomes the foreground color and the foreground color the background color. I want to do this as part of ksh script. Can somebody tell me how to do this ? Thanks, Abu. (5 Replies)
Discussion started by: marcose
5 Replies

2. Shell Programming and Scripting

reverse of basename

Hi, Can someone let me know how to find the reverse of the basename i.e i have /apps/tiv/pmon/xxxx.dat and I want /apps/tiv/pmon/ Thanks (7 Replies)
Discussion started by: braindrain
7 Replies

3. Shell Programming and Scripting

Reverse FTP

Hi Everybody, I want to write a script in unix which will automatically FTP a .txt file from my client machine D: drive(Windows) That is I want to FTP a file from my PC to UNIX box but this should be done from UNIX box by a shell script. (i.e. I will invoke the script in UNIX and FTP will be... (4 Replies)
Discussion started by: ganesh123
4 Replies

4. Shell Programming and Scripting

reverse sort

Hello, How do i sort a csv file. i should be sorting column1(varchar),column2*(varchar) in ascending and column4 in descending order(numeric datatype). I tried few combinations of sort, but doesn't seem to be getting the right result. sort -t "," -k 1 -k 2 -k 4nr file any help is... (3 Replies)
Discussion started by: markjason
3 Replies

5. Shell Programming and Scripting

Reverse multiword

Just check out the script... 1 #!/bin/bash 2 3 echo -n "Enter a string :: " 4 read str 5 echo -n "Reverse is :: " 6 l=`expr length "$str"` 7 while 8 do 9 m=`echo $str | cut -c "$l"` 10 echo -n $m 11 ... (3 Replies)
Discussion started by: lipun4u
3 Replies

6. Shell Programming and Scripting

reverse matching

Hello guys How can I use egrep to match word1 but not word2...word1. What I mean suppose that I have the following text, and my word1=pizza and word2=eat I hate to eat pizza because I ma eating it each day Pizza is good I like vegetarian and Italian Pizza eating healthy food is... (7 Replies)
Discussion started by: fdc2suxs
7 Replies

7. Shell Programming and Scripting

Reverse of a string

Hi All, I have a String str="Manish". I would like to reverse it. I know the option to do this in bash is: echo "Manish" | rev but I have seen an alternate solution somewhere, which states that: str="Manish" echo $str | awk '{ for(i=length($0);i>=1;i--) printf("%s",substr($0,i,1));... (7 Replies)
Discussion started by: manishdivs
7 Replies

8. Shell Programming and Scripting

Reverse sort

Hello, I have a large list of names and would like to do a reverse sort on them i.e. the sort should be by the ending and not by the beginning of the word. I had written in awk a small script but it does wrong things { for(i=length($0);i>=1;i--) printf("%s/n",substr($0,i,1)); } Could anyone... (3 Replies)
Discussion started by: gimley
3 Replies

9. Shell Programming and Scripting

Reverse even lines

I'm trying to reverse every even line in my file using the awk command below but it prints only the odd lines but nothing else: $ awk '(NR % 2) {print}; !(NR % 2) {print | "rev";}' myfile Any idea what I might have done wrong? Thank you. (10 Replies)
Discussion started by: ivpz
10 Replies
flow-mask(1)						      General Commands Manual						      flow-mask(1)

NAME
flow-mask -- Apply tags to flow files. SYNOPSIS
flow-mask [-hk] [-b big|little] [-C comment] [-d debug_level] [-m mask_fname] [-M active_def ...] DESCRIPTION
The flow-mask utility is used to modify the source and destination mask length's in flow records. OPTIONS
-b big|little Byte order of output. -C Comment Add a comment. -d debug_level Enable debugging. -h Display help. -k Keep time from input. -m mask_fname Load masks from mask_name. Defaults to /etc/flow-tools/cfg/mask -M mask_def Use active_def as the active tag definition(s). The configuration file is a collection of definitions. A definition lists a sequence of prefixes and the mask length to replace the match- ing prefix with. Lines begining with # are treated as comments and ignored. mask-definition command Description ---------------------------------------------------------------------- mask-definition Begin mask-definition section mask-definition foo prefix List the prefix to match on and the replacement mask. prefix 128.146/16 24 EXAMPLES
# #file: masks # mask-definition foo # All networks in 128.146/16 are /24's. prefix 128.146/16 24 # except for 128.146.214/24, which are /32's. prefix 128.146.214/24 32 flow-cat flows | flow-mask -mfoo -Fmasks | flow-print -f4 FILES
Configuration files: Mask - /etc/flow-tools/cfg/mask.cfg. BUGS
None known. AUTHOR
Mark Fullmer maf@splintered.net SEE ALSO
flow-tools(1) flow-mask(1)
All times are GMT -4. The time now is 08:10 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy