Re: [Tiki-devel] New -a option for setup.sh

Re: [Tiki-devel] New -a option for setup.sh

Hi Brendan

No great preference on the name, svnup.php is shorter, which is nice! :)

What i wanted to say though was have you used the Symfony console application as the framework? I just wanted to recommend it as you get all sorts of fun things like progress bars, built in docs and formatting and stuff for (almost) free!

> On 7 May 2017, at 12:48, Brendan Ferguson <[hidden email]> wrote:
>
> Ya, I will upload that soon. I haven't had s lot of time to work on projects. It's working now but have been working on a way to update secdb at the same time. Debugging it has been time consuming.
>
> There is also some REF I've wanted to complete on it.
>
> It is working though. So perhaps I should just upload what I've got and continue to work on it as I have time.
>
> I had named it svnupdate.php. I think svnup.php might also work. Any votes?
>
> Brendan
>
>
>
>> On May 7, 2017, at 4:54 AM, Marc Laporte <[hidden email]> wrote:
>>
>> Hi Brendan,
>>
>> I look forward to using your new script and deprecate
>> https://dev.tiki.org/Automatic+Updates#Test_script>>
>> This will save a lot of time of a lot of people.
>>
>> For example, by clearing cache before an update, issues like this
>> would be better handled: https://dev.tiki.org/item6330 (although this
>> example if not ideal because it is a major upgrade, and not a simple
>> svn up in the same branch)
>>
>> As for the name:
>> * doc/devtools/update.php ?
>> * doc/devtools/svnupdate.php ?
>> * something else?
>>
>> Thanks!
>>
>> On Tue, Apr 11, 2017 at 12:34 AM, Brendan Ferguson
>> <[hidden email]> wrote:
>>> yup. I’ve moved it over to php. It still however calls “sh setup.sh”, but
>>> baby steps I guess.
>>>
>>> Brendan
>>>
>>>
>>>
>>> On Apr 11, 2017, at 12:29 AM, Marc Laporte <[hidden email]> wrote:
>>>
>>> For the record, I would much prefer doc/devtools/svnupdate.php than
>>> doc/devtools/svnupdate.sh so it just works on all platforms.
>>>
>>> On Tue, Apr 11, 2017 at 12:18 PM, Marc Laporte <[hidden email]> wrote:
>>>
>>> Hi Brendan,
>>>
>>> Thank you very much for tackling this. I will convert my servers to
>>> use what you made instead of
>>> https://dev.tiki.org/Automatic+Updates#Test_script>>>
>>> For the question "console.php or keep it in doc/devtools?"
>>>
>>> Very good question. I'd love to hear Jonny's thoughts on this. I
>>> suspect he will say doc/devtools/svnupdate.sh
>>>
>>> * On one hand, upgrading a Tiki site is something a site admin should
>>> be able to do, and not just for Tiki developers
>>> * On the other hand, using console.php to upgrade Tiki (and
>>> potentially upgrade itself) is like a surgeon operating on
>>> his/herself. This is why TRIM is an external tool:
>>> https://doc.tiki.org/TRIM>>>
>>> So perhaps best place is doc/devtools/svnupdate.sh
>>>
>>> A full re-index is a good idea after any upgrade which could
>>> theoretically make a tangible change in that area. However, since full
>>> re-index can be quite long on some big sites, some folks may
>>> appreciate a flag like sh doc/devtools/svnupdate.sh --noindexrebuild
>>> (or something like that)
>>>
>>> Thanks!
>>>
>>> On Tue, Apr 11, 2017 at 1:07 AM, Brendan Ferguson <[hidden email]>
>>> wrote:
>>>
>>> So Ive got a script now that integrates the best of:
>>>
>>> https://dev.tiki.org/Automatic+Updates#Test_script>>>
>>> doc/devtools/svnupdate.sh
>>>
>>> Its also got some enhancements, mostly user friendly stuff, like logging and
>>> verbiage.
>>>
>>> Do we want the integrated into console.php or keep it in doc/devtools?
>>>
>>> Brendan
>>>
>>>
>>>
>>> On Apr 6, 2017, at 10:10 PM, Marc Laporte <[hidden email]> wrote:
>>>
>>> This is what I add for each Tiki:
>>> https://dev.tiki.org/Automatic+Updates#Test_script>>> I put it at the root and I call update.sh and sometimes I put it on a
>>> nightly cron job.
>>>
>>> I didn't commit because I am worried of adding noise to the code base.
>>> There is already doc/devtools/svnup.sh (which is missing features vs
>>> update.sh) and there is also https://doc.tiki.org/TRIM#make_update>>> which has more features and can now be used locally, but it requires
>>> an additional installation.
>>>
>>> I believe all this should be merged into one master script that is
>>> part of Tiki and well all use. I am not sure which is the best path
>>> though...
>>>
>>> Best regards,
>>>
>>> M ;-)
>>>
>>>
>>> On Fri, Apr 7, 2017 at 5:18 AM, Brendan Ferguson <[hidden email]>
>>> wrote:
>>>
>>> I got tired of hitting enter again and again. So now in trunk you can run
>>> "sh setup.sh -a", if you dont want to wear out your return key :)
>>>
>>> I was also thinking of creating some kind of option to run "sh setup.sh -a",
>>> "php console.php d:u", and "console.php cache:clear”
>>>
>>> The idea being that there might be a single command you can use after svn
>>> up. Im mostly thinking dev environments here.
>>>
>>> Any preferences on where to place that? Im guessing that console.php is
>>> probably the right place for it… thoughts?
>>>
>>> Brendan
>>>
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>>> _______________________________________________
>>> TikiWiki-devel mailing list
>>> [hidden email]>>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>>>
>>>
>>>
>>>
>>> --
>>> Marc Laporte
>>>
>>> http://WikiSuite.org>>> http://PluginProblems.com>>> http://Avan.Tech>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>>> _______________________________________________
>>> TikiWiki-devel mailing list
>>> [hidden email]>>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>>> _______________________________________________
>>> TikiWiki-devel mailing list
>>> [hidden email]>>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>>>
>>>
>>>
>>>
>>> --
>>> Marc Laporte
>>>
>>> http://WikiSuite.org>>> http://PluginProblems.com>>> http://Avan.Tech>>>
>>>
>>>
>>>
>>> --
>>> Marc Laporte
>>>
>>> http://WikiSuite.org>>> http://PluginProblems.com>>> http://Avan.Tech>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>>> _______________________________________________
>>> TikiWiki-devel mailing list
>>> [hidden email]>>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>>> _______________________________________________
>>> TikiWiki-devel mailing list
>>> [hidden email]>>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>>>
>>
>>
>>
>> --
>> Marc Laporte
>>
>> http://WikiSuite.org>> http://PluginProblems.com>> http://Avan.Tech>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot>> _______________________________________________
>> TikiWiki-devel mailing list
>> [hidden email]>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot> _______________________________________________
> TikiWiki-devel mailing list
> [hidden email]> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

Re: [Tiki-devel] New -a option for setup.sh

just wanted to bring it to attention that I’ve uploaded the first version of the update script into trunk.

I tried using symphony to implement options, but ran into a snag. I will re-try soon. So right now the verbiage and rebuilding the index are not optional, but they soon will be.

I was also able to fix the issue I had with secdb. It will now only update secdb if there is no chance of including a malicious file in it. With a few changes to the way secdb is generated, I can loosen that up a little so files in /storage (etc.) dont prevent the database from being updated.

So even though I’m not quite done, I think it should work well in most situations now.

No great preference on the name, svnup.php is shorter, which is nice! :)

What i wanted to say though was have you used the Symfony console application as the framework? I just wanted to recommend it as you get all sorts of fun things like progress bars, built in docs and formatting and stuff for (almost) free!

For example, by clearing cache before an update, issues like thiswould be better handled: https://dev.tiki.org/item6330 (although thisexample if not ideal because it is a major upgrade, and not a simplesvn up in the same branch)

As for the name:* doc/devtools/update.php ?* doc/devtools/svnupdate.php ?* something else?

Thank you very much for tackling this. I will convert my servers touse what you made instead ofhttps://dev.tiki.org/Automatic+Updates#Test_script

For the question "console.php or keep it in doc/devtools?"

Very good question. I'd love to hear Jonny's thoughts on this. Isuspect he will say doc/devtools/svnupdate.sh

* On one hand, upgrading a Tiki site is something a site admin shouldbe able to do, and not just for Tiki developers* On the other hand, using console.php to upgrade Tiki (andpotentially upgrade itself) is like a surgeon operating onhis/herself. This is why TRIM is an external tool:https://doc.tiki.org/TRIM

So perhaps best place is doc/devtools/svnupdate.sh

A full re-index is a good idea after any upgrade which couldtheoretically make a tangible change in that area. However, since fullre-index can be quite long on some big sites, some folks mayappreciate a flag like sh doc/devtools/svnupdate.sh --noindexrebuild(or something like that)

This is what I add for each Tiki:https://dev.tiki.org/Automatic+Updates#Test_scriptI put it at the root and I call update.sh and sometimes I put it on anightly cron job.

I didn't commit because I am worried of adding noise to the code base.There is already doc/devtools/svnup.sh (which is missing features vsupdate.sh) and there is also https://doc.tiki.org/TRIM#make_updatewhich has more features and can now be used locally, but it requiresan additional installation.

I believe all this should be merged into one master script that ispart of Tiki and well all use. I am not sure which is the best paththough...

I got tired of hitting enter again and again. So now in trunk you can run"sh setup.sh -a", if you dont want to wear out your return key :)

I was also thinking of creating some kind of option to run "sh setup.sh -a","php console.php d:u", and "console.php cache:clear”

The idea being that there might be a single command you can use after svnup. Im mostly thinking dev environments here.

Any preferences on where to place that? Im guessing that console.php isprobably the right place for it… thoughts?

Brendan

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

--Marc Laporte

http://WikiSuite.orghttp://PluginProblems.comhttp://Avan.Tech

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

--Marc Laporte

http://WikiSuite.orghttp://PluginProblems.comhttp://Avan.Tech

--Marc Laporte

http://WikiSuite.orghttp://PluginProblems.comhttp://Avan.Tech

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

-- Marc Laporte

http://WikiSuite.orghttp://PluginProblems.comhttp://Avan.Tech

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel

------------------------------------------------------------------------------Check out the vibrant tech community on one of the world's mostengaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________TikiWiki-devel mailing list[hidden email]https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel