Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Mon 02 May 2016, 19:35
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
Make-Diff-n-Patch GUI
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [4 Posts]  
Author Message
LazY Puppy


Joined: 21 Nov 2014
Posts: 968
Location: Germany

PostPosted: Tue 29 Dec 2015, 21:54    Post subject:  Make-Diff-n-Patch GUI
Subject description: A RoxApp GUI Program to make diff of files and execute the patches
 

Hi.

This is: Make-Diff-n-Patch GUI 0.0.7

Thanks to 666philb I had lately learned something very useful just a short time after I was on the search for a solution to replace text blocks inside of scripts. Suddenly I did understand how to use functions: diff and patch.

Function diff seems to be default in Puppy and is used to check contents of files for differences. Function patch seems to be default in Puppy's devx sfs and is used to add the differences found to the original file. (simple description)

As I'm quiet often in the need to make a diff of files and as I was doing this usually manually by eye sight in geany, I felt in love with the use of diff and patch.

So I created Make-Diff-n-Patch-GUI, a little RoxApp Program Directory to do diff and patch in a little more comfortable way.

If clicking the RoxApp Directory the GUI appears on the screen. You can drag and drop original and rewrite files into entry fields or choose these files from file selector.

There are three options to set up:

- Create a .diff File for 'patch'
- Copy .diff File to Original
- Execute 'patch' immediately


I think they are self explaining though there are two (more or less) special features.

1. Creating a .diff file will load the results into the GUI's integrated text editor and the GUI switches to the Results tab.

2. When copying the .diff File to where the original File is located this will give another feature to the user.
This way one can execute diff at all files that needs to be checked for differences. To patch those original Files can be easily done some later just by drag 'n' drop either the original file or the .diff file onto the Make-Diff-n-Patch-GUI RoxApp Program Directory.

Just extract the attached .tar.gz file to a ext partition.

Oh, and not to forget: as long as the devx sfs is located at boot partition or boot directory, it will load the devx sfs automatically.
Make-Diff-n-Patch-GUI.tar.gz
Description 
gz

 Download 
Filename  Make-Diff-n-Patch-GUI.tar.gz 
Filesize  39.68 KB 
Downloaded  44 Time(s) 

_________________
RSH

T.O.P.L.E.S.S. - the Multi-Language Puppy Linux Wrapper.
Just use one single frugal install of a Puppy Linux (32 & 64bit) to be personalised in many different ways.
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 968
Location: Germany

PostPosted: Wed 30 Dec 2015, 19:36    Post subject: Patch for /usr/bin/Extract-pet
Subject description: After the patch /usr/bin/Extract-pet will extract gz AND xz compressed .pet packages!
 

Ok.

I had made recently an observation about .pet packages and its content.

In earlier Puppies when extracting a .pet file, it extracts a .tar.gz file which then is extracted by /usr/bin/Extract-pet to give back the contents of the package.

In newer Puppies when extracting a .pet file, it extracts a .tar.xz file (which is xz compressed then) and trying to extract this by /usr/bin/Extract-pet will fail as there is no code applied to handle the extracted .xz archive.

So I made a little modification of Extract-pet to handle extracted .gz files as well as .xz files and it has been successfully tested using shinobar's frugalinstaller-2.1.1pet (which is xz compressed (edit: it was xz compressed but now new uploaded so probably now also gz compressed)) plus a package of my own (which is gz compressed).

After that modification I used Make-Diff-n-Patch GUI to create a .diff file to patch the original file: /usr/bin/Extract-pet.

Just remove the fake .gz file extension and copy the file to: /usr/bin.

Done?

Now drag and drop the /usr/bin/Extract-pet.diff file onto the Make-Diff-n-Patch GUI RoxApp Program Directory and the Extract-pet of your Puppy should now be able to extract gz AND xz compressed .pet packages without to complain anything.
Extract-pet.diff.gz
Description 
gz

 Download 
Filename  Extract-pet.diff.gz 
Filesize  969 Bytes 
Downloaded  32 Time(s) 

_________________
RSH

T.O.P.L.E.S.S. - the Multi-Language Puppy Linux Wrapper.
Just use one single frugal install of a Puppy Linux (32 & 64bit) to be personalised in many different ways.

Last edited by LazY Puppy on Wed 30 Dec 2015, 22:49; edited 1 time in total
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 968
Location: Germany

PostPosted: Wed 30 Dec 2015, 22:44    Post subject: Patch for /sbin/dir2sfs
Subject description: Make SFS Modules from Directories as well as from Symbolic Links to Directories
 

Hi.

This is a patch for /sbin/dir2sfs.

After the patch is applied to /sbin/dir2sfs it still makes SFS Modules from Directories but also from Symbolic Links (relative) to Directories. The original dir2sfs fails when trying to build a SFS Module from a symbolic link to a directory.

To keep two different named directories with equal content is not really comfortable, so to use a symbolic link would be the best of all choices.

Example:

The Directory to build the T.O.P.L.E.S.S. windowmanager.sfs is originally named to LP3_JWM-MenuPipes which I need that way for my different remastered LazY Puppy versions. But to build automatically the e.g. windowmanager_tahr_6.0.2.sfs for tahr 6.0.2 dir2sfs needs the directory named windowmanager to create the windowmanager.sfs which is then used to create the windowmanager_tahr_6.0.2.sfs.

Another example of use would be a directory with no version number added to be able to run scripts doing actions on the files in the directory. Using a symbolic link to the directory and adding a version number will create a SFS Module with version number added to the file name. No need to edit the scripts again to change paths to the new used version number in the directory's name.

Example of 'doing actions on the files in the directory' would be a script that will update edited files from within Puppy to the external directory for the SFS Module to build.

Im doing it this way as I'm generally working on the files inside of Puppy. If all went well I'm executing a script that is updating all newer changed files to the external directory of the SFS Module to be build.

Just changing the version number in the name of the symbolic link and a new version labeled SFS can be build immediately without to rename its original directory's name.
dir2sfs.diff.gz
Description 
gz

 Download 
Filename  dir2sfs.diff.gz 
Filesize  2.86 KB 
Downloaded  36 Time(s) 

_________________
RSH

T.O.P.L.E.S.S. - the Multi-Language Puppy Linux Wrapper.
Just use one single frugal install of a Puppy Linux (32 & 64bit) to be personalised in many different ways.
Back to top
View user's profile Send private message 
bigpup


Joined: 11 Oct 2009
Posts: 7418
Location: Charleston S.C. USA

PostPosted: Thu 31 Dec 2015, 02:31    Post subject:  

Hope you are doing Pull Requests at Woof CE for some of this coding.
https://github.com/puppylinux-woof-CE/woof-CE

_________________
I have found, in trying to help people, that the things they do not tell you, are usually the clue to solving the problem.
When I was a kid I wanted to be older.... This is not what I expected Shocked
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [4 Posts]  
Post new topic   Reply to topic 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.0374s ][ Queries: 12 (0.0045s) ][ GZIP on ]