Issue Details (XML | Word | Printable)

Key: MDL-15249
Type: Sub-task Sub-task
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Petr Skoda
Reporter: Petr Skoda
Votes: 0
Watchers: 3
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle
MDL-17458

convert, fix and improve CLI installler

Created: 15/Jun/08 07:42 PM   Updated: 04/Jun/09 12:29 AM
Return to search
Component/s: Administration
Affects Version/s: 2.0
Fix Version/s: 2.0

Participants: Penny Leach and Petr Skoda
Security Level: None
Resolved date: 04/Jun/09
Affected Branches: MOODLE_20_STABLE
Fixed Branches: MOODLE_20_STABLE


 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Petr Skoda made changes - 15/Jun/08 07:59 PM
Field Original Value New Value
Summary convert dml in cli installer convert, fix and improve CLI installler
Petr Skoda made changes - 15/Jun/08 08:00 PM
Parent Issue MDL-15094 [ MDL-15094 ] MDL-14679 [ MDL-14679 ]
Petr Skoda added a comment - 15/Jun/08 08:05 PM
hmm - the CLI installer/upgrade code is not nice at all and needs to be rewritten

Petr Skoda committed 4 files to 'Moodle CVS' - 15/Jun/08 08:23 PM
MDL-15249 improving cli installer
MODIFY admin/Attic/cliupgrade.php   Rev. 1.18    (+4 -8 lines)
MODIFY install.php   Rev. 1.102    (+2 -77 lines)
MODIFY lib/installlib.php   Rev. 1.5    (+17 -563 lines)
ADD lib/clilib.php   Rev. 1.1    (+0 -0 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 15/Jun/08 08:41 PM
MDL-15249 improving cli installer
MODIFY admin/Attic/cliupgrade.php   Rev. 1.19    (+35 -68 lines)
Penny Leach added a comment - 19/Jun/08 11:05 PM
Petr can you elaborate?

Petr Skoda added a comment - 20/Jun/08 03:30 AM
There is was too much duplication of code, the installib.php was incorrectly used for cli stuff instead of install stuff.
Also there are too many ifs, we should imo add general cli support and share much more code between /install.php, /admin/index.php. cli installer and cron

This can wait a bit, I hope this summer we will be working on weblib/pagelib rewrite.
In any case I did not test my changes in cli code yet, I am also planning several more ddl related (exceptions - yay!) and general session changes (I hope I will commit everything this weekend).

Any help will be appreciated later


Petr Skoda made changes - 29/Nov/08 03:05 AM
Parent Issue MDL-14679 [ MDL-14679 ] MDL-17458 [ MDL-17458 ]
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 01:17 AM
MDL-15249 refactoring normal installer in preparation for new cli installer
MODIFY lib/installlib.php   Rev. 1.16    (+52 -3 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 01:18 AM
MDL-15249 refactoring normal installer in preparation for new cli installer + coding style changes
MODIFY install.php   Rev. 1.131    (+21 -51 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 01:33 AM
MDL-15249 preparation for new cli installer + coding style changes
MODIFY lib/weblib.php   Rev. 1.1256    (+15 -72 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 01:43 AM
MDL-15249 removing copy of getopt, using standard version instead
MODIFY lib/profilerlib.php   Rev. 1.5    (+1 -231 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 01:44 AM
MDL-15249 preparation for new cli installer + license header
MODIFY lib/upgradelib.php   Rev. 1.12    (+71 -7 lines)
Petr Skoda committed 4 files to 'Moodle CVS' - 26/May/09 04:55 AM
MDL-15249 $_SERVER['HTTP_HOST'] not availabel in CLI script, replaced by parsing of wwwroot which should give the same info
MODIFY lib/moodlelib.php   Rev. 1.1209    (+13 -0 lines)
MODIFY mod/chat/settings.php   Rev. 1.2    (+2 -2 lines)
MODIFY admin/settings/server.php   Rev. 1.68    (+2 -2 lines)
MODIFY lib/db/install.php   Rev. 1.12    (+3 -3 lines)
Petr Skoda committed 2 files to 'Moodle CVS' - 26/May/09 05:04 AM
MDL-15249 fixed installation warnings
MODIFY mod/assignment/settings.php   Rev. 1.3    (+5 -3 lines)
MODIFY mod/forum/settings.php   Rev. 1.6    (+5 -3 lines)
Petr Skoda committed 3 files to 'Moodle CVS' - 26/May/09 05:46 AM
MDL-15249 towards cli install script
MODIFY lib/db/install.php   Rev. 1.13    (+2 -2 lines)
MODIFY user/editadvanced_form.php   Rev. 1.29    (+1 -6 lines)
MODIFY user/view.php   Rev. 1.205    (+7 -2 lines)
Petr Skoda committed 2 files to 'Moodle CVS' - 26/May/09 05:52 PM
MDL-15249 refactoring towards cli install script
MODIFY admin/index.php   Rev. 1.384    (+29 -85 lines)
MODIFY lib/upgradelib.php   Rev. 1.14    (+142 -5 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 26/May/09 05:56 PM
MDL-15249 whitespaces and comments cleanup, no other changes
MODIFY admin/index.php   Rev. 1.385    (+353 -353 lines)
Petr Skoda committed 2 files to 'Moodle CVS' - 26/May/09 06:21 PM
MDL-15249 more cleanup, removing unused code, adding some TODOs
MODIFY admin/Attic/maintenance.php   Rev. 1.19    (+3 -1 lines)
MODIFY admin/index.php   Rev. 1.386    (+26 -39 lines)
Petr Skoda committed 3 files to 'Moodle CVS' - 27/May/09 01:44 AM
MDL-15249 more cleanup and refactoring - towards cli upgrade
MODIFY admin/index.php   Rev. 1.387    (+1 -21 lines)
MODIFY lib/upgradelib.php   Rev. 1.15    (+24 -0 lines)
MODIFY lib/weblib.php   Rev. 1.1258    (+6 -1 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 27/May/09 03:02 AM
MDL-15249 more cleanup and refactoring - towards cli upgrade
MODIFY lib/upgradelib.php   Rev. 1.16    (+34 -101 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 27/May/09 04:34 PM
MDL-15249 error status codes for exceptions and notices
MODIFY lib/weblib.php   Rev. 1.1259    (+5 -5 lines)
Petr Skoda committed 5 files to 'Moodle CVS' - 27/May/09 05:52 PM
MDL-15249 sample cli scripts - sample implementation only, no localization - ideally we should now decide what parameters we need - let the heated discussion begin ;-)
ADD admin/cli/upgrade.php   Rev. 1.1    (+0 -0 lines)
DEL admin/Attic/cliupgrade.php   Rev. 1.42    (+0 -0 lines)
ADD admin/cli/install.php   Rev. 1.1    (+0 -0 lines)
ADD admin/cli/reset_password.php   Rev. 1.1    (+0 -0 lines)
MODIFY lib/clilib.php   Rev. 1.4    (+104 -537 lines)
Petr Skoda added a comment - 27/May/09 05:53 PM

Petr Skoda committed 1 file to 'Moodle CVS' - 29/May/09 03:45 PM
MDL-15249 help now printed if config.php exists
MODIFY admin/cli/install.php   Rev. 1.2    (+40 -37 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 30/May/09 10:36 PM
MDL-15249 major install lang file cleanup - removing all strings added into 2.0dev that are not going to be used at all
MODIFY lang/en_utf8/install.php   Rev. 1.34    (+1 -98 lines)
Petr Skoda committed 5 files to 'Moodle CVS' - 31/May/09 01:14 AM
MDL-15249 towards localized cli installer
MODIFY install/stringnames.txt   Rev. 1.25    (+9 -2 lines)
MODIFY admin/cli/install.php   Rev. 1.3    (+88 -77 lines)
MODIFY lang/en_utf8/admin.php   Rev. 1.286    (+5 -0 lines)
MODIFY lang/en_utf8/install.php   Rev. 1.35    (+4 -1 lines)
MODIFY lib/clilib.php   Rev. 1.5    (+29 -0 lines)
Petr Skoda committed 3 files to 'Moodle CVS' - 31/May/09 03:02 AM
MDL-15249 towards localized cli installer
MODIFY admin/cli/install.php   Rev. 1.4    (+11 -13 lines)
MODIFY lang/en_utf8/admin.php   Rev. 1.287    (+3 -0 lines)
MODIFY lang/en_utf8/install.php   Rev. 1.36    (+4 -1 lines)
martignoni committed 2 files to 'Lang CVS' - 31/May/09 06:56 PM
MDL-15249 New strings for localized cli
MODIFY fr_utf8/admin.php   Rev. 1.370    (+5 -1 lines)
MODIFY fr_utf8/install.php   Rev. 1.42    (+4 -1 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 31/May/09 07:45 PM
MDL-15249 installer fully localized
MODIFY admin/cli/install.php   Rev. 1.5    (+6 -3 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 31/May/09 07:50 PM
MDL-15249 yet more localization fixes for installer
MODIFY admin/cli/install.php   Rev. 1.6    (+2 -2 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 31/May/09 07:57 PM
MDL-15249 localized cli upgrade
MODIFY admin/cli/upgrade.php   Rev. 1.2    (+14 -9 lines)
martignoni committed 2 files to 'Lang CVS' - 31/May/09 08:03 PM
MDL-15249, new strings
MODIFY fr_utf8/install.php   Rev. 1.43    (+4 -1 lines)
MODIFY fr_utf8/admin.php   Rev. 1.371    (+6 -2 lines)
Petr Skoda committed 3 files to 'Moodle CVS' - 31/May/09 08:04 PM
MDL-15249 localization fixes
MODIFY admin/cli/upgrade.php   Rev. 1.3    (+1 -1 lines)
MODIFY admin/cli/install.php   Rev. 1.7    (+1 -1 lines)
MODIFY admin/cli/reset_password.php   Rev. 1.2    (+2 -2 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 31/May/09 08:13 PM
MDL-15249 password reset cli script improvements
MODIFY admin/cli/reset_password.php   Rev. 1.3    (+4 -3 lines)
Petr Skoda committed 1 file to 'Moodle CVS' - 31/May/09 08:34 PM
MDL-15249 password reset cli script improvements
MODIFY admin/cli/reset_password.php   Rev. 1.4    (+1 -1 lines)
Petr Skoda committed 2 files to 'Moodle CVS' - 31/May/09 08:38 PM
MDL-15249 yet more localization fixes
MODIFY admin/cli/reset_password.php   Rev. 1.5    (+1 -1 lines)
MODIFY admin/cli/upgrade.php   Rev. 1.4    (+1 -1 lines)
Petr Skoda committed 2 files to 'Moodle CVS' - 31/May/09 08:39 PM
MDL-15249 localized cli upgrade
MODIFY admin/cli/reset_password.php   Rev. 1.6    (+0 -2 lines)
MODIFY lang/en_utf8/admin.php   Rev. 1.288    (+1 -0 lines)
martignoni committed 1 file to 'Lang CVS' - 31/May/09 11:33 PM
MDL-15249 String added
MODIFY fr_utf8/admin.php   Rev. 1.372    (+2 -1 lines)
Mitsuhiro Yoshida committed 2 files to 'Lang CVS' - 03/Jun/09 03:17 AM
MDL-15249 Translated new strings for cli installer.
MODIFY ja_utf8/install.php   Rev. 1.49    (+81 -75 lines)
MODIFY ja_utf8/README   Rev. 1.1007    (+1 -1 lines)
Petr Skoda committed 3 files to 'Moodle CVS' - 04/Jun/09 12:24 AM
MDL-15249 support for environment test in cli scripts
MODIFY lib/environmentlib.php   Rev. 1.40    (+103 -8 lines)
MODIFY admin/cli/install.php   Rev. 1.8    (+14 -0 lines)
MODIFY admin/cli/upgrade.php   Rev. 1.5    (+15 -3 lines)
Petr Skoda added a comment - 04/Jun/09 12:29 AM
all the duplication should be removed now, seems to work fine without nay warnings or notices now, please note it runs in full debug and error display mode now
thanks

Petr Skoda made changes - 04/Jun/09 12:29 AM
Resolution Fixed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]
martignoni committed 1 file to 'Lang CVS' - 06/Jun/09 01:30 AM
MDL-15249 major install lang file cleanup, added comment for obsolete strings to delete in v2.0
MODIFY fr_utf8/install.php   Rev. 1.44    (+62 -62 lines)
Mitsuhiro Yoshida committed 2 files to 'Lang CVS' - 06/Jun/09 01:30 PM
MDL-15249 MDL-19352 MDL-18976 Translated new strings for admin.
MODIFY ja_utf8/admin.php   Rev. 1.354    (+16 -1 lines)
MODIFY ja_utf8/README   Rev. 1.1009    (+1 -1 lines)