(OLD) (ARCHIVED) Puppy Linux Discussion Forum Forum Index (OLD) (ARCHIVED) Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info

This forum can also be accessed as http://oldforum.puppylinux.com
It is now read-only and serves only as archives.

Please register over the NEW forum
https://forum.puppylinux.com
and continue your work there. Thank you.

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups    
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 05 Dec 2020, 07:48
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
PeasyDiff File Comparison Tool
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies. View previous topic :: View next topic
Page 1 of 1 [8 Posts]  
Author Message
rcrsn51


Joined: 05 Sep 2006
Posts: 13129
Location: Stratford, Ontario

PostPosted: Fri 13 May 2016, 12:28    Post subject:  PeasyDiff File Comparison Tool  

PeasyDiff is a replacement for Xfdiff-cut in the Utility menu. It has a simpler drag-and-drop file selection method and fewer distracting graphics. The default display is vertical, or you can select "Side-by-side" and get a two-column display.

PeasyDiff also dumps its output into the file /tmp/PeasyDiff.txt for "off-line" use. Click the View button to open the file in a text editor.

PeasyDiff can compare two individual files or a pair of folders.

The Spacing option includes differences in white space when files are compared. If you turn it off, any differences in spacing are ignored.

----------------------

Version 1.4 introduces a configuration file to hold the PeasyDiff settings. Look for the hidden file /root/.peasydiff.

Code:
export DIMENSIONS="40 120"
export VERTOPTIONS=""
export SBSOPTIONS="-y --suppress-common-lines --width=130"
export FONT="Monospace bold 12"

DIMENSIONS sets the size of the output window.
SBSOPTIONS sets the diff command options for side-by-side output.
FONT sets the display font.

If you accidentally break the file, just delete it and restart PeasyDiff.
screenie.png
 Description   
 Filesize   13.33 KB
 Viewed   223 Time(s)

screenie.png

peasydiff-1.4.pet
Description  Updated 2017-04-06
pet

 Download 
Filename  peasydiff-1.4.pet 
Filesize  3.96 KB 
Downloaded  274 Time(s) 

Last edited by rcrsn51 on Thu 06 Apr 2017, 21:35; edited 15 times in total
Back to top
View user's profile Send private message 
musher0

Joined: 04 Jan 2009
Posts: 15041
Location: Gatineau (Qc), Canada

PostPosted: Fri 13 May 2016, 17:59    Post subject:  

Hi rcrsn51.

Thanks for this very useful visualization utility for diff.

BFN

_________________
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)
Back to top
View user's profile Send private message 
B.K. Johnson

Joined: 12 Oct 2009
Posts: 810

PostPosted: Fri 13 May 2016, 22:33    Post subject:  

Hi rcrsn51
I welcome the addition of another 'diff'. However, the display on my first pair of files was less than stellar.

The line separating the columns got broken and when I dragged the edges of the display to see if I could adjust the output, I found the display would not scale; a large white space was left on rhe right side.

See attached part of the display.

I want this to work.
sample.png
Description  section of display
png

 Download 
Filename  sample.png 
Filesize  36.48 KB 
Downloaded  424 Time(s) 

_________________
B.K. Johnson
tahrpup-6.0.5 PAE (upgraded from 6.0 =>6.0.2=>6.0.3=>6.0.5 via quickpet/PPM=Not installed); slacko-5.7 occasionally. Frugal install, pupsave file, multi OS flashdrive, FAT32 , SYSLINUX boot, CPU-Dual E2140, 4GB RAM

Back to top
View user's profile Send private message 
rcrsn51


Joined: 05 Sep 2006
Posts: 13129
Location: Stratford, Ontario

PostPosted: Sat 14 May 2016, 06:44    Post subject:  

B.K. Johnson wrote:
The line separating the columns got broken

Thanks for reporting this. PeasyDiff is pretty simple - it just takes the output of the diff command and dumps it into an Xdialog text box. With regular vertical display, this is good enough.

With side-by-side display, there are two problems.

1. The diff command uses tab characters to align the columns. If you run diff in a terminal window this works correctly. But in the Xdialog box, the tabs get messed up.

2. A terminal window uses a fixed-width font for proper alignment. Xdialog claims to have this option, but I can't get it to work.

But there is a partial solution. Get v1.2 above and run side-by-side. The Xdialog display will still be wonky. But the file /tmp/PeasyDiff.txt will now align properly. If you are looking at a complicated comparison, this is probably the best way to do it.

[Edit] To make this easier, I have added a View button that takes you directly to the text file.

If you want to change the comparison method for side-by-side, look at line 10 of /usr/sbin/peasydiff and modify the OPTIONS variable.
Back to top
View user's profile Send private message 
B.K. Johnson

Joined: 12 Oct 2009
Posts: 810

PostPosted: Sat 14 May 2016, 09:58    Post subject:  

@rcrsn51
You wrote:
Quote:
But there is a partial solution. Get v1.2 above and run side-by-side. The Xdialog display will still be wonky. But the file /tmp/PeasyDiff.txt will now align properly. If you are looking at a complicated comparison, this is probably the best way to do it.


Just as you wrote: display still wonky but file /tmp/PeasyDiff.txt and View are OK.
This will do. Thanks.

_________________
B.K. Johnson
tahrpup-6.0.5 PAE (upgraded from 6.0 =>6.0.2=>6.0.3=>6.0.5 via quickpet/PPM=Not installed); slacko-5.7 occasionally. Frugal install, pupsave file, multi OS flashdrive, FAT32 , SYSLINUX boot, CPU-Dual E2140, 4GB RAM

Back to top
View user's profile Send private message 
rcrsn51


Joined: 05 Sep 2006
Posts: 13129
Location: Stratford, Ontario

PostPosted: Sat 14 May 2016, 10:27    Post subject:  

B.K. Johnson wrote:
Just as you wrote: display still wonky but file /tmp/PeasyDiff.txt and View are OK.
This will do.

I will also have a fix for the Xdialog display shortly.
Back to top
View user's profile Send private message 
B.K. Johnson

Joined: 12 Oct 2009
Posts: 810

PostPosted: Sat 14 May 2016, 13:36    Post subject:  

@rcrsn51
What's the constraint that limits the output (both Diff and View) to 64 chars per line?

_________________
B.K. Johnson
tahrpup-6.0.5 PAE (upgraded from 6.0 =>6.0.2=>6.0.3=>6.0.5 via quickpet/PPM=Not installed); slacko-5.7 occasionally. Frugal install, pupsave file, multi OS flashdrive, FAT32 , SYSLINUX boot, CPU-Dual E2140, 4GB RAM

Back to top
View user's profile Send private message 
rcrsn51


Joined: 05 Sep 2006
Posts: 13129
Location: Stratford, Ontario

PostPosted: Sat 14 May 2016, 16:30    Post subject:  

Run: diff --help

Check out the "--width=NUM" option.

[Edit] In v1.4, you can set this with the configuration file:

Code:
export SBSOPTIONS="-y --suppress-common-lines --width=150"

I tested this. It appears to make the two columns 75 characters wide.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [8 Posts]  
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies. View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0557s ][ Queries: 13 (0.0201s) ][ GZIP on ]