Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 11th May 2005, 13:56   #1
aj kwak
Member
 
Join Date: Mar 2005
Posts: 57
vpatch

I dont know why, but the vpatch system works not like i want.

I just want :
I have a file (example text.txt)
and i have made a update of the file.
So i want that the file text.txt will be upgraded to the newtext.txt

what i have with vpatch now :
i have oldfile.txt on my directory and if i take a patch then i get 2 files oldfile.txt and newfile.txt
So... thats not a patchsystem...
aj kwak is offline   Reply With Quote
Old 11th May 2005, 14:28   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,338
Take a look at the example in Contrib\VPatch.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 11th May 2005, 14:47   #3
aj kwak
Member
 
Join Date: Mar 2005
Posts: 57
Quote:
Originally posted by kichik
Take a look at the example in Contrib\VPatch.
I have used the example...
aj kwak is offline   Reply With Quote
Old 11th May 2005, 14:54   #4
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,338
So what's the problem? You've got your new file, copy it over the old file. Or rename the old file before patching it and delete it if the patch was successful.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 12th May 2005, 07:51   #5
aj kwak
Member
 
Join Date: Mar 2005
Posts: 57
Quote:
Originally posted by kichik
So what's the problem? You've got your new file, copy it over the old file. Or rename the old file before patching it and delete it if the patch was successful.
So what's the meaning of vpatch?
If i make a little installer with the files that must be upgraded. And if i use SetOverwrite on, than have i the same?

example
SetOverwrite on
File "C:\unicode.txt"

the only thing is that the upgrade.exe or patch.exe is bigger than if i use vpatch.
aj kwak is offline   Reply With Quote
Old 12th May 2005, 07:59   #6
aj kwak
Member
 
Join Date: Mar 2005
Posts: 57
The strange thing about vpatch and GENPAT is, that the sourcefile and the targetfile have another filename.
GENPAT (sourcefile) (targetfile) (patchfile)
vpatch::vpatchfile "patch.pat" data.txt" "data_new.txt"

and the thing i want is something like this:

vpatch::vpatchfile "patch.pat" "old\file.txt" "new\file.txt"
Same name but another folder. I want to make an 'automaticaly patch-system'
if the software developer dump his files and run a batch-file, there would make a patch.exe in the background.
aj kwak is offline   Reply With Quote
Old 12th May 2005, 09:14   #7
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,338
VPatch is better than simply using SetOverwrite, if you have big files that change only slightly. It allows you to include only the changed parts of the file. It also allows you to easily include patches for multiple version in one patch file.

VPatch and GenPat don't expect different file names, they expect different paths to different files. Using the same file name in different directories should work.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 13th May 2005, 08:01   #8
aj kwak
Member
 
Join Date: Mar 2005
Posts: 57
Why would my .pat-file not work?
I always get 'Patch data is invalid or corrupt'
or
after extracting the pat-file
'Unable to open output file'
aj kwak is offline   Reply With Quote
Old 14th May 2005, 12:28   #9
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,338
Maybe the parameter order is incorrect or the patch file really is corrupt. Attach an example.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 19th August 2005, 18:30   #10
Koen van de Sande
Senior Member
 
Join Date: Mar 2001
Location: Holland
Posts: 269
Upgrade to VPatch 3.0 RC7. There is a critical bugfix which should solve your corrupt patches (if you make them again from scratch ).

Get it now: http://www.tibed.net/vpatch

Koen van de Sande
Van de Sande Productions
TibEd.net | VPatch
Koen van de Sande is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump