-
Notifications
You must be signed in to change notification settings - Fork 48
Add Missing Strings Validation for Moodle Plugin CI #356
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Add Missing Strings Validation for Moodle Plugin CI #356
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #356 +/- ##
============================================
- Coverage 88.31% 85.06% -3.25%
- Complexity 761 1637 +876
============================================
Files 77 114 +37
Lines 2344 4619 +2275
============================================
+ Hits 2070 3929 +1859
- Misses 274 690 +416 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
94f10f2
to
dd9f119
Compare
- Add a comprehensive language string validation tool for Moodle plugins - Validates required strings, detects missing/unused strings from PHP, JavaScript, templates, and database files - Includes automatic subplugin discovery and validation
dd9f119
to
8817822
Compare
Wow, that is the biggest PR to this project I have ever seen! 🥇Well done @volodymyrdovhan, missing strings check definitely would be useful to have. Do you have some performance info, it is fast on projects with numerous strings? |
84f6082
to
dcd824a
Compare
dcd824a
to
6609072
Compare
Hi @kabalin, Here are some stats for some Moodle core plugins. mod/assign:
mod/quiz
mod/lesson
mod/bigbluebuttonbn/
|
Summary
What It Checks
Code Usage
get_string()
andnew lang_string()
calls in PHPstr.get_string()
,str.get_strings()
,getString()
,getStrings()
,Prefetch
methods){{#str}}
,{{#cleanstr}}
)->addHelpButton()
)$row->state
are ignored)Plugin Requirements
pluginname
modulename
,modulenameplural
Subplugin Support
db/subplugins.json
anddb/subplugins.php
Usage
# Basic validation moodle-plugin-ci missingstrings /path/to/plugin