Author Topic: move without backup and UNINSTALL_ORDER  (Read 3173 times)

-Turambar90-

  • Guest
move without backup and UNINSTALL_ORDER
« on: January 20, 2011, 06:23:51 AM »
Is it possible to allow the MOVE command to support the no backup option like the COPY command (eg, MOVE + ~file~ ~directory~ )?

If it is not, I'd need to use an UNINSTALL_ORDER command. I haven't understood how it works: is it
U_O ~MOVE - STRSET - COPY - AT~ (from the description of the default order)
U_O ~MOVE STRSET COPY AT~
U_O ~MOVE~ ~STRSET~ ~COPY~ ~AT~
or what?

Offline the bigg

  • The Avatar of Fighter / Thieves
  • Moderator
  • Planewalker
  • *****
  • Posts: 3804
  • Gender: Male
Re: move without backup and UNINSTALL_ORDER
« Reply #1 on: January 20, 2011, 07:01:21 AM »
Yes, I can make MOVE +, but that's a "don't use this feature without a real reason". That said, the standard syntax for passing a list of strings is U_O ~MOVE~ ~STRSET~ ~COPY~ ~AT~.
Author or Co-Author: WeiDU (http://j.mp/bLtjOn) - Widescreen (http://j.mp/aKAiqG) - Generalized Biffing (http://j.mp/aVgw3U) - Refinements (http://j.mp/bLHoCc) - TB#Tweaks (http://j.mp/ba02Eg) - IWD2Tweaks (http://j.mp/98OFYY) - TB#Characters (http://j.mp/ak8J55) - Traify Tool (http://j.mp/g1Ry9A) - Some mods that I won't mention in public
Maintainer: Semi-Multi Clerics (http://j.mp/9UeIwB) - Nalia Mod (http://j.mp/dng9l0) - Nvidia Fix (http://j.mp/aRWjjg)
Code dumps: Detect custom secondary types (http://j.mp/hVzzXG) - Stutter Investigator (http://j.mp/gdtBn8)

If possible, send diffs, translations and other contributions using Git (http://j.mp/aBZFrq).

-Turambar90-

  • Guest
Re: move without backup and UNINSTALL_ORDER
« Reply #2 on: January 20, 2011, 07:56:50 AM »
Yes, I can make MOVE +, but that's a "don't use this feature without a real reason". That said, the standard syntax for passing a list of strings is U_O ~MOVE~ ~STRSET~ ~COPY~ ~AT~.
thanks. Is it possible to write an example such as this one in the WeiDU documentation, to make it clearer?
Anyway, I do really need it: I'm trying to translate the batch instructions at the end of SOS into WeiDU instructions, but, since the files which are MOVEd are deleted afterwards, during uninstallation, the MOVEs can't be undone, the uninstallation fails and the AT_UNINSTALLs are not performed (which results in an incorrect backup).
Moving move to the end of the uninstallation would make the error appear after the uninstallation process is actually complete; but MOVE + would be a much better thing to do, as it does not influence the whole mod

Offline the bigg

  • The Avatar of Fighter / Thieves
  • Moderator
  • Planewalker
  • *****
  • Posts: 3804
  • Gender: Male
Re: move without backup and UNINSTALL_ORDER
« Reply #3 on: January 20, 2011, 08:04:17 AM »
Sometimes, when trying to improve the solution of a problem, it is better not to reproduce the solution with an optimization, but rather take a step back, analyze the problem, and implement an entirely different solution.
Author or Co-Author: WeiDU (http://j.mp/bLtjOn) - Widescreen (http://j.mp/aKAiqG) - Generalized Biffing (http://j.mp/aVgw3U) - Refinements (http://j.mp/bLHoCc) - TB#Tweaks (http://j.mp/ba02Eg) - IWD2Tweaks (http://j.mp/98OFYY) - TB#Characters (http://j.mp/ak8J55) - Traify Tool (http://j.mp/g1Ry9A) - Some mods that I won't mention in public
Maintainer: Semi-Multi Clerics (http://j.mp/9UeIwB) - Nalia Mod (http://j.mp/dng9l0) - Nvidia Fix (http://j.mp/aRWjjg)
Code dumps: Detect custom secondary types (http://j.mp/hVzzXG) - Stutter Investigator (http://j.mp/gdtBn8)

If possible, send diffs, translations and other contributions using Git (http://j.mp/aBZFrq).

-Turambar90-

  • Guest
Re: move without backup and UNINSTALL_ORDER
« Reply #4 on: January 20, 2011, 09:52:39 AM »
Sometimes, when trying to improve the solution of a problem, it is better not to reproduce the solution with an optimization, but rather take a step back, analyze the problem, and implement an entirely different solution.
Well, the problem was somewhere else (the AT_UNINSTALL was in an action_if controlled by a variable), and it works now. Anyway, I would prefer to have MOVE + for some parts of that mod, if it's possible. Thanks

Offline the bigg

  • The Avatar of Fighter / Thieves
  • Moderator
  • Planewalker
  • *****
  • Posts: 3804
  • Gender: Male
Re: move without backup and UNINSTALL_ORDER
« Reply #5 on: January 20, 2011, 10:04:54 AM »
MOVE + is possible and going in. I'm just pointing out that, if SoS is moving + deleting files, then you shouldn't replicate that behavior blindly. In particular, the biffing routine used by SoS and the like breaks [R]einstall and wastes space and time in a BiG environment. You should take a look at what Lollorian's Trimpack does, but the better procedure for compatibility with [R]einstall and BiG:

- WED, BAM, MOS, BMP, TIS, WAV resources are (if necessary) decompressed in their source folder and then MOVEd in one (or more) appropriate directories, on which MAKE_BIFF is called. The files must remain in the temp directory for [R]einstall to work.
- The other resources (ITM, SPL, CRE, BCS, DLG, ARE, ...) are copied (compiled, appended) in the override, and then left there - no biffing, no moving, etc.
Author or Co-Author: WeiDU (http://j.mp/bLtjOn) - Widescreen (http://j.mp/aKAiqG) - Generalized Biffing (http://j.mp/aVgw3U) - Refinements (http://j.mp/bLHoCc) - TB#Tweaks (http://j.mp/ba02Eg) - IWD2Tweaks (http://j.mp/98OFYY) - TB#Characters (http://j.mp/ak8J55) - Traify Tool (http://j.mp/g1Ry9A) - Some mods that I won't mention in public
Maintainer: Semi-Multi Clerics (http://j.mp/9UeIwB) - Nalia Mod (http://j.mp/dng9l0) - Nvidia Fix (http://j.mp/aRWjjg)
Code dumps: Detect custom secondary types (http://j.mp/hVzzXG) - Stutter Investigator (http://j.mp/gdtBn8)

If possible, send diffs, translations and other contributions using Git (http://j.mp/aBZFrq).

-Turambar90-

  • Guest
Re: move without backup and UNINSTALL_ORDER
« Reply #6 on: January 22, 2011, 03:08:37 AM »
MOVE + is possible and going in. I'm just pointing out that, if SoS is moving + deleting files, then you shouldn't replicate that behavior blindly. In particular, the biffing routine used by SoS and the like breaks [R]einstall and wastes space and time in a BiG environment. You should take a look at what Lollorian's Trimpack does, but the better procedure for compatibility with [R]einstall and BiG:

- WED, BAM, MOS, BMP, TIS, WAV resources are (if necessary) decompressed in their source folder and then MOVEd in one (or more) appropriate directories, on which MAKE_BIFF is called. The files must remain in the temp directory for [R]einstall to work.
- The other resources (ITM, SPL, CRE, BCS, DLG, ARE, ...) are copied (compiled, appended) in the override, and then left there - no biffing, no moving, etc.
I think that using AT_NOW and AT_UNINSTALL instead of the _EXIT options should not break [R]einstall, as the situation is completely re-established to the initial one before the new install takes place.

I think some INTERACTIVE checks can be used to make SOS behave the old way for interactive installations, and how BWP wants for the BWP ones

PS: whom can I ask in order to register to this forum? My request is still pending...

-Turambar90-

  • Guest
Re: move without backup and UNINSTALL_ORDER
« Reply #7 on: January 22, 2011, 03:57:08 AM »
I think some INTERACTIVE checks can be used to make SOS behave the old way for interactive installations, and how BWP wants for the BWP ones
BTW, what happens in the following situation?

override/file already exists, and has to be overwritten by folder/file.
Code: [Select]
MOVE ~folder/file~ ~override~the old file should be backed up.
After the installation, I completely remove folder

What happens when I uninstall? is the original file restored, while the new file disappears, or does the new file remain in the override folder (as it cannot be moved back to folder)?
Would anything change if I COPY it instead of MOVing it?

What happens if file already exists (as in the situation above), but in a bif? Is the new one removed from the override folder?

Offline the bigg

  • The Avatar of Fighter / Thieves
  • Moderator
  • Planewalker
  • *****
  • Posts: 3804
  • Gender: Male
Re: move without backup and UNINSTALL_ORDER
« Reply #8 on: January 22, 2011, 06:00:59 AM »
I think that using AT_NOW and AT_UNINSTALL instead of the _EXIT options should not break [R]einstall, as the situation is completely re-established to the initial one before the new install takes place.
--make-biff is not compatible with [R]einstall, if that's what you're asking.

If the target file exists, MOVE behaves as COPY. I don't know and don't care what happens if you delete a file somewhere.
Author or Co-Author: WeiDU (http://j.mp/bLtjOn) - Widescreen (http://j.mp/aKAiqG) - Generalized Biffing (http://j.mp/aVgw3U) - Refinements (http://j.mp/bLHoCc) - TB#Tweaks (http://j.mp/ba02Eg) - IWD2Tweaks (http://j.mp/98OFYY) - TB#Characters (http://j.mp/ak8J55) - Traify Tool (http://j.mp/g1Ry9A) - Some mods that I won't mention in public
Maintainer: Semi-Multi Clerics (http://j.mp/9UeIwB) - Nalia Mod (http://j.mp/dng9l0) - Nvidia Fix (http://j.mp/aRWjjg)
Code dumps: Detect custom secondary types (http://j.mp/hVzzXG) - Stutter Investigator (http://j.mp/gdtBn8)

If possible, send diffs, translations and other contributions using Git (http://j.mp/aBZFrq).

-Turambar90-

  • Guest
Re: move without backup and UNINSTALL_ORDER
« Reply #9 on: February 09, 2011, 04:22:09 AM »
Another question about MOVE and uninstalling: I've tried the following code:
Code: [Select]
MOVE ~try/file~ ~try/file3~
MOVE ~try/file3~ ~try/file2~
and I've noticed that, when you uninstall it, neither of the move actions is reverted, ie, I still have file2 in the try folder.
Although I don't know why anyone should move anything twice (at least, I think it's always possible to find a way around that, but I can't be sure), is that the expected behaviour? Could it be useful to point that out in the documentation?

Offline the bigg

  • The Avatar of Fighter / Thieves
  • Moderator
  • Planewalker
  • *****
  • Posts: 3804
  • Gender: Male
Re: move without backup and UNINSTALL_ORDER
« Reply #10 on: February 09, 2011, 04:35:24 AM »
Moves (and copies) are uninstalled in the same order as they're performed, rather than in inverted order. This can lead to problems like this one.
Author or Co-Author: WeiDU (http://j.mp/bLtjOn) - Widescreen (http://j.mp/aKAiqG) - Generalized Biffing (http://j.mp/aVgw3U) - Refinements (http://j.mp/bLHoCc) - TB#Tweaks (http://j.mp/ba02Eg) - IWD2Tweaks (http://j.mp/98OFYY) - TB#Characters (http://j.mp/ak8J55) - Traify Tool (http://j.mp/g1Ry9A) - Some mods that I won't mention in public
Maintainer: Semi-Multi Clerics (http://j.mp/9UeIwB) - Nalia Mod (http://j.mp/dng9l0) - Nvidia Fix (http://j.mp/aRWjjg)
Code dumps: Detect custom secondary types (http://j.mp/hVzzXG) - Stutter Investigator (http://j.mp/gdtBn8)

If possible, send diffs, translations and other contributions using Git (http://j.mp/aBZFrq).

 

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Name: Email:
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image
Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?: