I am using the below command to get the diff output of two files.
Here in the output file, I wish to add line number in front of each line starting position.
Please suggest the diff options or some command line utilities.
Hello, I need help in appending the line number of each line to the file and also to get the total number of lines. Can somebody please help me.
I have a file say:
abc
def
ccc
ddd
ffff
The output should be:
Instance1=abc
Instance2=def
Instance3=ccc
Instance4=ddd
Instance5=ffff
... (2 Replies)
Hi,
I have a huge file & I want to add a specific text in column. But I want to add this text from a specific line number to a specific line number & another text in to another range of line numbers.
To be more specific: lets say my file has 1000 lines & 4 Columns. I want to add text "Hello"... (2 Replies)
Hi Everybody,
I am trying to write a script that will get some perticuler data from a file and redirect to a file.
My Question is,
I have a Very huge file,In that file I have my required data is started from 25th line and it will ends in 100th line.
I know the line numbers, I need to get all... (9 Replies)
Hello,
I have to compare two files file1 and file2, retrieve the number of lines modified (added, deleted or modified) in file2. Output must be like:
File2:
Added Deleted Changed Total
------ ------- -------- -----
2 1 1 4
Somebody... (2 Replies)
Hello Everyone.
I am trying to display contains of a file from a specific line to a specific line(let say, from line number 3 to line number 5). For this I got the shell script as shown below:
if ; then
if ; then
tail +$1 $3 | head -n $2
else
... (5 Replies)
Hello everyone,
I don't really know anything about scripting, but I have to manage to make this script, out of necessity.
#!/bin/bash
while read -r line; do #I'm reading from a big wordlist
instructions using $line
done
Is there a way to automatically write the $line number the script... (4 Replies)
I am looking for help in processing of those options: '-n' or '-p'
I understand what they do and how to use them.
But, I would like to use them with more than one file (and without any shell-loop; loading the 'perl' once.)
I did try it and -n works on 2 files.
Question is:
- is it possible to... (6 Replies)
Discussion started by: alex_5161
6 Replies
LEARN ABOUT CENTOS
rpmdev-diff
RPMDEV-DIFF(1) User Commands RPMDEV-DIFF(1)NAME
rpmdev-diff - manual page for rpmdev-diff version 1.4
SYNOPSIS
rpmdev-diff [OPTION]... [DIFF-OPTIONS] FROM-ARCHIVE TO-ARCHIVE
DESCRIPTION
rpmdev-diff diffs contents of two archives.
See rpmdev-extract(1) for information about supported archive types.
OPTIONS -c, --contents
Diff contents of files in archives. This is the default.
-l, --list
Diff lists of files in archives.
-L, --long-list
Diff long lists (akin to 'find -ls') of files in archives.
-m, --metadata
Diff archive metadata (only implemented for rpms for now).
-h, --help
Print help message and exit.
-v, --version
Print version information and exit.
diff-options
Options passed to diff(1). The first repeated argument of the above or the first argument starting with a '-' but not one of the
above starts diff-options, the first one not starting with it ends them. Default: -Nup for contents (in addition to -r which will
always be passed), -U0 for others.
More than one of -c, -l, -L, and -m may be specified.
REPORTING BUGS
Report bugs to <https://bugzilla.redhat.com/>.
COPYRIGHT
Copyright (C) 2004-2010 Ville Skytta <ville.skytta@iki.fi> This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
rpmdev-diff version 1.4 June 2014 RPMDEV-DIFF(1)