chore: upgrade scaffolding#97
Conversation
- Fix all onesearch/OneSearch branding references across scaffold files - Update CI/CD workflows: release.yml, ci.yml, reusable-build.yml, reusable-wp-playground-pr-preview.yml (artifact names, zip filenames) - Fix .github/.codecov.yml plugin path - Fix .github/PULL_REQUEST_TEMPLATE.md repository links - Update blueprint.json metadata for OneLogs - Fix .phpcs.xml.dist: description, filename, prefixes, text domain - Update phpunit.xml.dist to PHPUnit 11.5 format with correct paths - Delete phpcs.xml.dist (superseded by .phpcs.xml.dist, contained wrong phpunit content) - Fix phpstan.neon.dist: bootstrap and paths to onelogs.php - Update phpstan/stubs: remove OneSearch-specific Algolia properties - Fix .wp-env.json, .wp-env.test.json, .wp-env.child.json plugin paths - Fix .gitignore zip filename - Restore webpack.config.js entry points: logs-dashboard (OneLogs-specific), settings (index.js), remove search entry (OneSearch-specific) - Fix composer.json strauss namespace/classmap/constant prefixes - Fix docs/CONTRIBUTING.md, DEVELOPMENT.md, SECURITY.md - Fix tests/php/bootstrap.php, TestCase.php namespaces OneLogs\ namespaces - Delete tests/php/Unit/Modules/Search/ (module does not exist in OneLogs) - Fix tests/_data/plugins/localhost-helper.php - Fix tests/e2e/settings/activation.spec.ts CSS classes and plugin file OneLogsSettings globals - Rewrite tests/js/utils.test.ts for OneLogs constants/utils API - Fix tests/js/OnboardingScreen.test.tsx for onelogs_site_type - Fix tests/js/SiteModal.test.tsx: OneLogs token header, REST path - Delete OneSearch-specific JS tests: AlgoliaSettings, SiteSearchSettings, SettingsPage, MultiSelectChips, SiteIndexableEntities - Fix jest.config.js displayName and comment Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…olia/strauss from composer.json 'onelogs' - composer.json: remove strauss block (algolia/algoliasearch-client- OneLogs has no Algolia usagephp) - composer.json: remove strauss scripts (prefix-namespaces, post-install-cmd, post-update-cmd) - composer.json: update clean script to only rm vendor (not vendor-prefixed) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Refreshes the OneLogs plugin's scaffolding to match the plugin-skeleton-d template, then reapplies all OneLogs-specific customizations that were reset during import. The net effect is a large infrastructure overhaul: new reusable GitHub Actions workflows, Prettier/lefthook/lint-staged tooling, ESLint 9 + flat config, PHPUnit 11.5, PHPStan 2.x, PHP 8.2 platform, a Jest config, a new tsconfig.base.json, a Playwright e2e harness, a release-please pipeline, and a full PHP/JS test suite rewritten under OneLogs\ namespaces.
Changes:
- Scaffold reset: new root config files, reusable workflows, Prettier/lefthook/lint-staged tooling, ESLint flat config, PHPUnit 11.5 migration.
- OneLogs-specific reapplication: text-domain/namespace/prefix fixes, removed Algolia/Strauss, rewrote PHP and JS tests against OneLogs APIs.
- Dependency bumps: PHP
8.0 → 8.2, PHPUnit^11.5, PHPStan^2.1.54, eslint^9,@wordpress/scripts ^32,@wordpress/eslint-plugin ^25, plus 13 new devDependencies.
Reviewed changes
Copilot reviewed 90 out of 103 changed files in this pull request and generated 13 comments.
Show a summary per file
| File | Description |
|---|---|
| webpack.config.js | Re-derives shared config from new array-shaped @wordpress/scripts export, formats with tabs/single quotes |
| uninstall.php, onelogs.php | strict_types=1 → strict_types = 1 formatting |
| tsconfig.json, tsconfig.base.json | Splits compiler options into a base config consumed by both root and test tsconfigs |
| tests/php/**/*.php | New PHPUnit 11.5 test suite under OneLogs\Tests namespace |
| tests/js/*.{ts,tsx} | New Jest+RTL tests for utils/SiteTable/SiteModal/SiteSettings/OnboardingScreen and shared setup |
| tests/e2e/settings/activation.spec.ts | New Playwright activation/deactivation smoke test |
| tests/_data/plugins/localhost-helper.php | Dev mu-plugin to rewrite localhost → host.docker.internal for onelogs endpoints |
| playwright.config.ts, jest.config.js | New JS test harness wrappers around @wordpress/scripts defaults |
| phpunit.xml.dist, phpstan.neon.dist, phpstan/stubs/wordpress-extended.php | PHPUnit 11.5 schema, PHPStan 2.x params, empty stub file |
| phpcs.xml.dist (deleted) / .phpcs.xml.dist | Replaces inline ruleset with rtCamp shared ruleset |
| package.json, composer.json | Dependency bumps and rewritten scripts; new prefer-stable/autoload entries; php ^8.2 |
| blueprint.json, release-please-config.json, .release-please-manifest.json | New Playground blueprint and release-please configuration |
| eslint.config.mjs, .prettierrc.js, .prettierignore, .stylelint.config.js, .stylelintrc.json, .stylelintignore, .lefthook.yml, .lintstagedrc.mjs | New flat ESLint config + Prettier/stylelint/lefthook tooling |
| inc/**/*.php | Adds declare(strict_types = 1), drops trailing blanks, minor docblock trimming |
| assets/src/**/*.{js,ts,tsx} | Wide Prettier reformat (tabs + single quotes, no inner padding), small structural splits |
| .wp-env.json, .wp-env.test.json, .wp-env.child.json | Splits dev / test / child environments into separate configs |
| .github/workflows/*.yml, .github/PULL_REQUEST_TEMPLATE.md, .github/dependabot.yml, .github/.codecov.yml | Replaces monolithic test.yml/release.yml with a reusable workflow architecture + new PR-title, Copilot, codecov configs |
| .gitignore, .gitattributes, .editorconfig | Reorganizes ignore rules and adds export-ignore/editorconfig conventions |
| docs/{CONTRIBUTING,CODE_OF_CONDUCT,SECURITY}.md | Markdown reformatting and rewording |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
9924241 to
f0d5967
Compare
justlevine
left a comment
There was a problem hiding this comment.
Now we need someone else to approve it
338c37c to
37027cb
Compare
|
(e2e is failing because the repo needs to be renamed to |
Description
Updates the scaffolding per
plugin-skeleton-dand reapplies all OneLogs-specific plugin customizations that were reset during the scaffold import.Technical Details
Scaffold reset (from
plugin-skeleton-d):tests/php/, and.github/*with the latest scaffold.lefthook.yml,.lintstagedrc.mjs,.prettierrc.js,.prettierrc.js,.stylelint.config.js,eslint.config.mjs,tsconfig.base.json,playwright.config.ts, reusable GitHub Actions workflowsPlugin-specific migration (OneLogs customizations reapplied):
onesearch/OneSearch→onelogs/OneLogsreferences across CI workflows, PHP configs, env files, docs, and test fileswebpack.config.jsentry points (logs-dashboard,settings,onboarding) — removed OneSearch'ssearchentry.phpcs.xml.dist: prefixes, text domain, file pathsphpunit.xml.dist: upgraded schema PHPUnit 9.5 → 11.5, updated bootstrap and test pathsphpstan.neon.dist,.wp-env.json,blueprint.json,composer.json,jest.config.jsOneSearch\→OneLogs\)AdminTest,AlgoliaTest,PostRecordTest)AlgoliaSettings,SiteSearchSettings,SettingsPage,MultiSelectChips,SiteIndexableEntities)tests/js/utils.test.tsto test OneLogs constants/utilstests/js/setup.tsglobals (OneLogsSettings, correct field names)composer.json(OneLogs has no Algolia dependency)Dependency alignment with scaffold:
package.json: added 13 missing devDependencies (@testing-library/*,@playwright/test,lefthook,lint-staged,prettier,jest-watch-typeahead,@wordpress/prettier-config,@wordpress/stylelint-config,@typescript-eslint/*), bumped 8 packages to scaffold versions, upgradedeslintto^9(required by@wordpress/eslint-plugin ^25)composer.json: bumpedphpunit/phpunit→^11.5,phpstan→^2.1.54,wp-phpunit→^6.9, platform PHP8.0→8.2Testing
npm install✅composer install✅