[RFC] MOD Installation

Note: We are moving the topics of this forum and it will be deleted at some point

Publish your own request for comments/change or patches for the next version of phpBB. Discuss the contributions and proposals of others. Upcoming releases are 3.2/Rhea and 3.3.
igorw
Registered User
Posts: 500
Joined: Thu Jan 04, 2007 11:47 pm

Re: MOD Installation

Post by igorw »

That part is of course irrelevant for MOD installation.

Oleg
Posts: 1150
Joined: Tue Feb 23, 2010 2:38 am
Contact:

Re: MOD Installation

Post by Oleg »

A_Jelly_Doughnut wrote:
nn' wrote:I would like a facility to convert modx files to patch files and sql files.
I'm not seeing the broad applicability of a feature like this.
It's not broadly applicable, in fact it may well be considered an "advanced" feature.
Furthermore, I don't think anyone has the will to force another completely new format on MOD authors.
I never intended for patch files to take over modx. I simply wish for it to be a supported output format, let's put it this way.
nn- wrote: Even if patch can't express inline finds, at the moment of installation automod locates the lines it's going to modify and alter them. If in fact modx inline finds cannot be translated to patch hunks using modx information only, then patch generation is actually domain of automod as opposed to modx tools contrary to what was stated earlier.
I don't think I follow the logic. What does patch generation have to do with installing a MOD?
Currently installing mods can be done in two ways:

1. Manual installation following instructions in modx.
2. Installation via automod.

Let's agree that manual installation is something we don't want to do because it is too time consuming, which just leaves automod. Now automod is catered to people who, let's say, are not developers and who would rather not deal with source code at all. My problem with this approach is that it completely ignores developers who do care about the code.

I have local modifications on my board. Many of them are too specific to my environment to ever be distributed outside of my site. This is a fact and it's not going to change in foreseeable future. All of the code I deal with is version controlled (literally). Furthermore the code that php runtime executes is not directly something that lives in version control. Here is a simplified procedure I currently have to follow to install a mod via automod:

1. Upload mod to automod
2. Tell automod to install the mod, this gives me an archive of my board files
3. Unpack the archive, diff against deployed tree, arrive at a patch
4. Apply patch file to source tree

Last time I tried this the download didn't work so the actual process I did use was even more complicated and in the end failed to produce a usable result.

What I would like for automod to do is to give me patch file as output in step 2. There appears to be some debate whether a modx file can by itself be converted ta a patch file. If it can be then automod does not need to be involved, what I would be happy with is a supported tool that converts modx files to patches. If the only way to get a patch file out of a modx is to actually attempt to do the changes, then I would like automod to have an option of patch output in addition to tar/tar.gz/zip.

Finally if I could tell automod to generate the patch off an arbitrary path as base instead of phpbb root, life would be totally good.

One benefit of getting a patch is that it cannot be applied partially or multiple times or parts of it applied multiple times. Partial patch application is trivial to spot (the patch program complains), and reverting partial application is trivial on version controlled trees. So potentially patch output could be used with success by people who version control their code but do not have a hardcore deployment model.

igorw
Registered User
Posts: 500
Joined: Thu Jan 04, 2007 11:47 pm

Re: MOD Installation

Post by igorw »

Thanks for the detailed explanation. By cleaning up the code it would be trivial to create a command-line application that does just that.

./modx2diff /path/to/board < modx.xml

1. load modx file
2. run through all modx actions, but do not write the changes to disk
3. iterate over changed files, run each through phpBB's diff class, comparing current state with modx state in memory
4. output diff

I agree that such functionality can be useful.

User avatar
VSE
Extension Customisations
Extension Customisations
Posts: 673
Joined: Mon Mar 08, 2010 9:18 am

Re: MOD Installation

Post by VSE »

If Automod were added to Ascreus, it could use these updates (it can use them currently as well)

- A simple way to handle updating currently installed MODs to a new version. A built-in feature to detect new versions of your installed MODs, download them, and provide the Update button (instead of Install)!!

You just can't update MODs with the current Automod. I usually have to trick Automod (if I want it to do it) by putting the update.xml in the root folder, and renaming it to install, and removing the normal installer... And also remove any trace of the MOD from the Automod table in the database, or Automod will tell you it has already detected it as being installed.

- MOD deletion, like we have style deletion. Sometimes, users make a mess with Automod, and they end up with a situation in which the MOD did not get installed, or partially... But Automod logged it in to the DB, so they have no chance of being able to try re-installing the MOD because Automod will detect it as being installed. A delete option (not uninstall) that simply removes the MOD from the Automod table in the database could be very helpful too.
Has an irascible disposition.

User avatar
MichaelC
Development Team
Development Team
Posts: 889
Joined: Thu Jan 28, 2010 6:29 pm

Re: MOD Installation

Post by MichaelC »

VSE+ wrote:If Automod were added to Ascreus, it could use these updates (it can use them currently as well)

- A simple way to handle updating currently installed MODs to a new version. A built-in feature to detect new versions of your installed MODs, download them, and provide the Update button (instead of Install)!!
I belive this is planned by A_Jelly_Doughnut and eXtraction to find a way to link titania and automod to accomplish features such as this.
Formerly known as Unknown Bliss
psoTFX wrote: I went with Olympus because as I said to the teams ... "It's been one hell of a hill to climb"
No unsolicited PMs please except for quotes.

sajaki
Registered User
Posts: 86
Joined: Mon Jun 21, 2010 8:28 pm

Re: MOD Installation

Post by sajaki »

VSE+ wrote: You just can't update MODs with the current Automod. I usually have to trick Automod (if I want it to do it) by putting the update.xml in the root folder, and renaming it to install, and removing the normal installer... And also remove any trace of the MOD from the Automod table in the database, or Automod will tell you it has already detected it as being installed.
almost a year later now, and the above is still true. :cry:

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1834
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: [RFC] MOD Installation

Post by DavidIQ »

Is there a bug report for it? ;)
Image

User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: [RFC] MOD Installation

Post by imkingdavid »

Has there been a decision on this? Is someone working on integrating AutoMOD into 3.1, or starting from scratch? Or is it being bumped back to 3.2?

I might be willing to help some if needed, though once school starts back up my availability will be decreased.
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

Oleg
Posts: 1150
Joined: Tue Feb 23, 2010 2:38 am
Contact:

Re: [RFC] MOD Installation

Post by Oleg »

There have not been any updates/changes since viewtopic.php?p=220497#p220497.

Mod installation is blocked by hook system, hook system is kind of blocked by me working on the template engine at the moment. The most useful thing right now is to move the hook system forward by specifying how it should work and sketching out an architecture.

Michaelo
Registered User
Posts: 106
Joined: Thu Apr 01, 2004 7:56 am
Location: Dublin

Re: [RFC] MOD Installation

Post by Michaelo »

Surely with the long awaited hook system, it should be entirely possible to rewrite every mod removing the need to edit any core file... thereby allowing Automod to concentrate on more important tasks...
Mods: Forum Icons Enhancement, Kiss Portal Engine
Links:
Kiss Portal Engine (dev site) Stargate Portal (archive site) ...
Styles: Technika

Post Reply