Jump to content











Photo
- - - - -

[solved] Does require_file now overwrite existing files?


  • Please log in to reply
48 replies to this topic

#26 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 11 February 2010 - 09:41 PM

My message above was not directed at you, but Lancelot or Galopo, who have fiddled with this special version.

btw. You wouldn't happen to know if CAPIv22 overwrites by default in NativeEx?

:cheers:

That is independent from CAPI:
CopyOrExpand, (which here is called from CAPI,) by default overwrites existing files w/o notice.
That is the original behaviour existing since that command has been introduced.
In later WB versions I introduced the 'PERSERVE' and some other options.
And if you do not give the PRESERVE to your native CopyOrExpand command, or to the corresponding CAPI function, it will overwrite.

Peter

#27 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 11 February 2010 - 09:43 PM

CAPI still needs a slight adjustment. #5 isn't defined most of the time, so WB throws an error because a null parameter is being specified.

I'll look to fix this exception.
Easier than to rewrite different CAPI functions.

Peter

#28 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 11 February 2010 - 09:49 PM

The old require_file of the API use with WB072 did clearly not overwrite existing files, else NaughtyPE should have had problems forever.


I'll look to fix this exception.
Easier than to rewrite different CAPI functions.

Not a good idea! I had 'Check Parameter Count' activated. And if the number of parameters is wrong, there should be a warning.

:cheers:

#29 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 11 February 2010 - 10:15 PM

@psc

I'll look to fix this exception.
Easier than to rewrite different CAPI functions.

I guess galapo means capi v15, no need fix with current capi 21b (22) about current topic findings, I already wrote it is working as expected.

@MedEvil

My message above was not directed at you, but Lancelot or Galopo, who have fiddled with this special version.

IF you ever read my second post on current topic or further posts, we are aware what is happening with the "fiddled version" v15rev7 and v21b (= v22 )version. Only now Galapo figured out the real reason v15rev7 fails which points a winbuilder bug that is newly fixed. Further we will fiddle more to fit old winbuilder requirement for LiveXP, please use any version you like but not v15rev7 or further rev, last unfiddled official version is v21, get from pedrole's signature, have fun. Or use api, it also does not overwrite. Feel free to :cheers: with your selections. Wish you the best of luck.

btw. You wouldn't happen to know if CAPIv22 overwrites by default in NativeEx?

No, it does not, we already happen to know you do not read what is written on this topic, and again and again.....

#30 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 11 February 2010 - 10:21 PM

I'll look to fix this exception.
Easier than to rewrite different CAPI functions.

Peter

Hi Peter,

If you're going to do this, which I think is a good idea, can you allow for the following possibilities:

CopyOrExpand,somefile,somelocation,PRESERVE
CopyOrExpand,somefile,somelocation,NOWARN
CopyOrExpand,somefile,somelocation,PRESERVE,NOWARN
CopyOrExpand,somefile,somelocation,NOWARN,PRESERVE
CopyOrExpand,somefile,somelocation,PRESERVE,
CopyOrExpand,somefile,somelocation,NOWARN,
CopyOrExpand,somefile,somelocation,,PRESERVE
CopyOrExpand,somefile,somelocation,,NOWARN

Thanks,
Galapo.

#31 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 12 February 2010 - 12:29 AM

No, it does not, we already happen to know you do not read what is written on this topic, and again and again.....

Stop arguing! If you guys can agree upon any facts, i will stick to it.

So far given info:
- Lancelot: latest version of CAPI is v21b
- Peter: NativeEx uses CAPI v22
- Galapo: LiveXP CAPI v15 is better than v21b for PE1
- Lancelot: Capi v15 overwrites
- Galapo: Capi v15 should not do that, WB bug
- Peter: WB bug fixed
- MedEvil: WB + Capi v15 still overwrite

:cheers:

#32 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 12 February 2010 - 12:35 AM

So far given info:
- Lancelot: latest version of CAPI is v21b
- Peter: NativeEx uses CAPI v22
- Galapo: LiveXP CAPI v15 is better than v21b for PE1
- Lancelot: Capi v15 overwrites
- Galapo: Capi v15 should not do that, WB bug
- Peter: WB bug fixed
- MedEvil: WB + Capi v15 still overwrite

Nope, still a couple more to add:

- Galapo: CAPI v15 often supplies a null parameter, will update api
- Peter: No need to do that, better to adjust WB
- Galapo: Agreed -- will save much headache with api (breathes sigh of relief)

Regards,
Galapo.

#33 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 12 February 2010 - 12:49 AM

Stop arguing!

Start Reading.

- Lancelot: latest version of CAPI is v21b

Wrong I wrote:

last unfiddled official version is v21

also I wrote:

v21b (aka v22) (and probably also v21) does not overwrite :cheers:

- Galapo: LiveXP CAPI v15 is better than v21b for PE1

I do not think Galapo ever compared v15 with v21 or 21b or 22 and wrote v15 is better.

- MedEvil: WB + Capi v15 still overwrite

there is no surprise with that.
Topic tells all the story:
nextwb + capi v15 rev7 -> not checked yet, according to conversation between psc and Galapo it will not overwrite (maybe a minor fix also required, written before)
wb77rc2 + capi v15 or rev7 -> always overwrite, will be fixed with rev8 to fit wb077rc2 needs. It is not fixed yet since it is not urgent for LiveXP project, Adjustments already made knowing v15 behaviour and request made on capi topic looong time ago to revert back which was reverted back by pedrole by finding a workaround to wb bug ...( These are also written before)....


Nothing new on current post. Only we happen to learn the know fact.

#34 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 12 February 2010 - 01:04 AM

Why don't you settle to call CAPI v22 DAPI V1 - codename "headless chickens" ? :cheers:

A new idea :cheers:: what about keeping a history log, possibly written in English and available (read only) to everyone, where whoever makes changes jolts down whatever he changed? :cheers:

Wonko

#35 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 12 February 2010 - 01:10 AM

Hi jaclaz,

history logs already exists for v15rev7 (inside script) and v22 (on api topic last psc post). :cheers:.
and as written before v22 works (which is the continum of latest v21, can be called as v21b to refer original) as expected (also written on post 7).

#36 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 12 February 2010 - 01:16 AM

A new idea :cheers:: what about keeping a history log, possibly written in English and available (read only) to everyone, where whoever makes changes jolts down whatever he changed? :cheers:

Exactly what Lancelot and I have done with the CAPI version on the LiveXP server:

[main]

Title=Common_Api

Description=(v15rev7 for LiveXP) This script contains a set of magic functions that you can use inside your script to make some tasks easier like creating shortcuts and extracting files.

...

Version=15

Revision=7

...

History15b=Lancelot : temporary adding for v15 to use arch for the new users that downloads from server - http://www.boot-land.net/forums/index.php?showtopic=9648&view=getlastpost

History15b=Lancelot : Not a vital adding since currently livexp do not support x64 today, log on errors can be ignored, besides it prevents user to get false alarm.

History15b=Lancelot : changes made following Galapo's lines at 0 - OnProjectRun.script

History15b=[Api_Def] - %APISUBDEF% -> Arch added to the end of line

History15b=[ApiVar] - following line added: Arch=Run,%API%,Arch_check

History15b=[Arch] and [Arch_check] sections added

History15rev3=Galapo updated [Run_FromRam1], [Run_FromCD1], [AddShortcut1], [Run_FromCD2]

History15rev4a=Lancelot with following Pedro Le 15 capi v21, Fixed Hiderun and ExpEnvVar path depending of %SourceArch%

History15rev4b=Lancelot by completing codes provided by Galapo (thanks boss) , [Expand_file1] & [Arch_check] + [Expand_1] sections modified to make require_file lines work properly with 32bit applications on wow64 enabled PEx64 build

History15rev4c=Galapo enhanced line at [Expand_file1]

History15rev5=Galapo updated [Arch_check] with further functionality

History15rev6=Lancelot Temporary fix for the bug found on winbuilder where network disabled -- "If,Not,ExistFile," adding before "WebGetIfNotExist" -  http://www.boot-land.net/forums/index.php?showtopic=10031

History15rev7=Lancelot Extract_And_Run - override the WB function to support x64 hostos + using %GlobalTemp% or %basedir%\Temp - topic: http://www.boot-land.net/forums/index.php?showtopic=9936 - bug topic: http://www.boot-land.net/forums/index.php?autocom=bugtracker&showbug=226

Regards,
Galapo.

#37 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 12 February 2010 - 01:20 AM

I do not think Galapo ever compared v15 with v21 or 21b or 22 and wrote v15 is better.

I did in fact write something along those lines to MedEvil a few days ago, but I confess to not really testing 21/21b/22.

By "better" I simply meant version 21/21b/22 has problems with x64 builds, specifically the require_file command. Version 21/21b/22 needs updating in this regard, also the [Arch_check] requires updating.

Regards,
Galapo.

#38 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 12 February 2010 - 01:23 AM

I did in fact write something along those lines to MedEvil

Sorry, I meant in limits of MedEvil expectation (which topic title says) you did not compare..... my faulty expression, I have my yellow card now. :cheers: :cheers:

#39 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 12 February 2010 - 01:28 AM

Hi jaclaz,

history logs already exists for v15rev7 (inside script) and v22 (on api topic last psc post). :cheers:.
and as written before v22 works (which is the continum of latest v21, can be called as v21b to refer original) as expected (also written on post 7).


Sure :rofl:, it also exists a third history version, in CAPI v16Alpha1rev2RC0.3*1/PI, there is only one copy of this, scribbled in Aramaic on the back of a paper towel I keep in the usual locked filing cabinet stuck in a disused lavatory with a sign on the door saying 'Beware of the Leopard'.

Come on, get real, you are effectively giving a whole new meaning to "versioning nightmare". :cheers:

As often happens, not at all my business, only trying to comply with my signature.

:cheers:

Wonko

#40 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 12 February 2010 - 01:41 AM

It is not our fault Jacklaz,

capi development continued to v21, than pedrole not available.

LiveXP stick to v15 because winbuilders after wb077rc2 always caused troubles with LiveXP.
(capi versions also have close relation to wb versions)
But life went on and we made 7 addition to fullfill requirements.
After a long while, psc found bug on v21 and published on his project saying v22. (with MedEvil expression, it is fiddled v21 :cheers:)

Further: Be sure capi will unite to single again in some time :cheers:

About topic:
I guess you totally understand topic wrongly. If MedEvil uses v22 with latest wb, and if his project have no problem with latest wb, there is no need such a topic. If MedEvil wants to use older wb with older capi, than he needs to fiddle with capi. Post 7 on current topic already provided that info.

Rest of the topic is finding - fixing a bug (which already noticed by pedrole and fixed with latest capi in the past) and not carelfull readings :rofl:.

It is simple, capi22 does not have a problem written current topic head, and future capies will not too. Is it too hard to get this conclusion :cheers:

#41 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 12 February 2010 - 01:46 AM

Sure :cheers:, it also exists a third history version, in CAPI v16Alpha1rev2RC0.3*1/PI, there is only one copy of this, scribbled in Aramaic on the back of a paper towel I keep in the usual locked filing cabinet stuck in a disused lavatory with a sign on the door saying 'Beware of the Leopard'.

If you can fight off the Leopard and jimmy the cabinet, I should be able to work on the Aramaic. But do we even know where this disused dunny is?

Regards,
Galapo.

#42 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 12 February 2010 - 01:48 AM

there is only one copy of this, scribbled in Aramaic on the back of a paper towel

I should be able to work on the Aramaic.

I totally missed that, I did not know winbuilder support Aramaic. :cheers: :cheers: :cheers:

#43 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 12 February 2010 - 02:11 AM

UPDATE!

Sorry :cheers: the leopard wasn't feeded properly and ate the paper towel (some residuals of a hamburger might have triggered this primordial behaviour, usually Leo is a very polite big cat).

The good news :cheers: is that he swallowed the thingy without chewing it, so if any of you two smart guys are willing to recover it, there is no problem, I do have available a pair of very long rubber gloves....:cheers:

:rofl:

Wonko

#44 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 12 February 2010 - 02:34 AM

Well, for me this Aramaic CAPI v16Alpha1rev2RC0.3*1/PI is deemed unrecoverable.

Thankfully we still have v15rev7 and v21/21v/22 in our possession.

Regards,
Galapo.

#45 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 12 February 2010 - 09:41 AM

Well, for me this Aramaic CAPI v16Alpha1rev2RC0.3*1/PI is deemed unrecoverable.

Thankfully we still have v15rev7 and v21/21v/22 in our possession.


Yep, it sucked anyway :cheers: , judging from the tracker it was used only by 2 and 3/8 users, before being replaced by CAPI v16Alpha1rev2RC0.3*1/3.15, codename "demented babybird".

I have however an image of it's cover:
Posted Image

:cheers:

Wonko

#46 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 12 February 2010 - 02:21 PM

Latest Trash with CAPI v15something works fine. No overwrite anymore. :cheers:
Will do a test with v22 too.

:cheers:

#47 Galapo

Galapo

    Platinum Member

  • .script developer
  • 3841 posts
  •  
    Australia

Posted 13 February 2010 - 08:05 AM

That's excellent news! I wasn't looking forward to having to muck around with the api merging require_file function of 15rev7 with 21/21b/22.

Thanks Peter for getting null parameters with CopyOrExpand working.

Regards,
Galapo.

#48 MedEvil

MedEvil

    Platinum Member

  • .script developer
  • 7771 posts

Posted 13 February 2010 - 02:09 PM

Capi v22 does also not overwrite.

So i think this topic can now be closed.

:cheers:

#49 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 13 February 2010 - 02:13 PM

So i think this topic can now be closed.

For the record, judging from it's actual usefulness, it could have been well been closed after post #7

:cheers:

Wonko




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users