Hi There,
I've written a script that processes a data file on our system. Basically the script reads a post code from a list file, looks in the data file for the first occurrence (using grep) and reads the line number. It then tails the data file, with the line number just read, and outputs to a... (3 Replies)
I'm trying to find a command which will allow me to remove a range of lines (2-4) from a .dat file from the command line without opening the file.
Someone mentioned using the ex command?
Does anyone have any ideas?
thanks (6 Replies)
Hi Gurus,
I'm a little new to UNIX. How can I do remove the first and last line in a file? Say, supppose I have a file as below:
Code:
1DMA
400002BARRIE
401002CALGARY/LETHBRI
402002CARLETON
500001PORTLAND-AUBRN
501001NEW YORK, NY
502001BINGHAMTON, NY ... (2 Replies)
Hi folks, I have a long string of DNA sequences, and I need to remove several lines, as well as the line directly following them. For example, here is a sample of my starting material:
>548::GY31UMJ02DLYEH rank=0007170 x=1363.5 y=471.0 length=478... (1 Reply)
Hi there, normally if I want to remove a user tht I have added to a specific group, i would do the following
this is what my group2 looks like
# grep group2 /etc/group
group2:x:7777:user2,user1,user4
user1 has been defined in a few groups
# id -nG user1
group1 group2 group3
So... (3 Replies)
I have a reference file that needs to remain static and another file that may or may not have duplicate rows that match the reference file. I need help with a command that will delete any duplicate rows from the second file while leaving reference file intact
For example reference file would... (4 Replies)
Hello Everyone,
I'm currently have a requirement where I've generated a list of files with specific attributes and I need to know what lines are similar between the two files. For example:
-File 1-
line1
line2
line3
-File 2-
line1
line2
line4
line5
-Desires Output-
line1
line2... (5 Replies)
Hi,
I have a linux server that was hacked and I have a bunch of files that sporadically contain the following lines through out the file:
<?php eval(base64_decode("Xxxxxxxxxxxxxx/xxxxxxxx"));
I did't put the exact lines of the file in this post. The "Xxxx" are random letters/numbers.... (8 Replies)
I have a file `/tmp/wrk` containing filenames with paths. I want to remove filenames
from this file, for example
remove all filenames containing alja cagr cavt clta cmdo or corl
remove all filenames containing data for days in region `d.2016.001` to `d.2016.207`
remove all filenames... (10 Replies)
Discussion started by: kristinu
10 Replies
LEARN ABOUT DEBIAN
vselect
vselect(1Vi)vselect(1Vi)NAME
vselect - select objects from a Vista data file
SYNOPSIS
vselect [-option ...] [infile] [outfile]
DESCRIPTION
vselect copies selected objects from an input file to an output file.
Command line options specify which objects are to be copied. Objects may be selected by type (e.g., all images), by name, by the value of
some attribute, or by position within the input file.
COMMAND LINE OPTIONS
vselect accepts the following options:
-help Prints a message describing options.
-in Specifies a Vista data file from which objects are to be selected.
-out Specifies where to write the selected objects as a Vista data file.
The input and output files can be specified on the command line or allowed to default to the standard input and output streams.
In addition, exactly one of the following options must be used to specify the objects to be selected:
-object i Select the ith object. Objects in the input file are numbered consecutively from 0.
-name name Select any object whose attribute name is name.
-type type Select any object whose type is type.
-attr name value
Select any object having an attribute with the specified name and value.
Finally, any of these selection criteria can be inverted:
-not Reverses the sense of the selection criterion.
EXAMPLES
To select the first object from a file:
vselect -object 0 < infile > outfile
To select the attribute named ``cantaloupe'' from a file:
vselect -name cantaloupe < infile > outfile
To select everything but images from a file:
vselect -type image -not < infile > outfile
To select images with ubyte pixels from a file of images:
vselect -attr nbands ubyte < infile > outfile
AUTHOR
Art Pope <pope@cs.ubc.ca>
Vista Version 1.12 24 April 1993 vselect(1Vi)