Welcome Guest.   Make a donation to an author on the site October 24, 2014, 03:32:46 PM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
The N.A.N.Y. Challenge 2014! Download dozens of custom programs!
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: DONE: HashReplace - Replace all files with identical contents  (Read 3831 times)
justice
Supporting Member
**
Posts: 1,889



Solve issues simply.

View Profile WWW Give some DonationCredits to this forum member
« on: June 15, 2011, 07:42:31 AM »

What it does:
Replace all files in a folder with identical filename AND SHA1 hash as original.file with new.file.

Use Cases
Say I have updated the contents of a php file that is used multiple times throughout my project, and now I want all other copies of that file to be updated as well.
In most cases the following code would work:
Formatted for Generic Code with the GeSHI Syntax Highlighter [copy or print]
  1. replace some_file.php c:\projects\example_project
However if the file is readme.txt or config.php for example, then you'd have overwritten many wrong copies. Using HashReplace only files with the same name and same contents will be overwritten with the new contents.

Download
Source, Executable and Test files
« Last Edit: June 15, 2011, 07:47:08 AM by justice » Logged

mouser
First Author
Administrator
*****
Posts: 33,587



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #1 on: June 15, 2011, 10:26:41 AM »

very nice idea!
Logged
justice
Supporting Member
**
Posts: 1,889



Solve issues simply.

View Profile WWW Give some DonationCredits to this forum member
« Reply #2 on: June 26, 2012, 07:16:08 AM »

If you want to play with the latest source, you can now fork from Bitbucket:
https://bitbucket.org/svandragt/hashreplace

I'll keep posting executable releases in this topic when they're available.
Logged

Pages: [1]   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.041s | Server load: 1.28 ]