Skip to content
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

🔨 chore: Mozart integration and update Appsero for WP 6.7 compatibility #48

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 35 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,20 @@
"minimum-stability": "dev",
"prefer-stable": true,
"require": {
"appsero/client": "dev-develop"
"appsero/client": "^v2.0.4"
},
"autoload": {
"psr-4": {
"Texty\\": "includes/"
"Texty\\": "includes/",
"Texty\\Dependencies\\": "dependencies/"
}
},
"require-dev": {
"tareq1988/wp-php-cs-fixer": "dev-master",
"wp-coding-standards/wpcs": "dev-develop",
"phpcompatibility/php-compatibility": "*",
"phpcompatibility/phpcompatibility-wp": "*",
"coenjacobs/mozart": "^0.7.1",
"dealerdirect/phpcodesniffer-composer-installer": "^0.7"
},
"scripts": {
Expand All @@ -32,11 +34,42 @@
],
"phpcbf": [
"phpcbf -p"
],
"post-install-cmd": [
"[ $COMPOSER_DEV_MODE -eq 0 ] || \"vendor/bin/mozart\" compose",
"composer dump-autoload"
],
"post-update-cmd": [
"[ $COMPOSER_DEV_MODE -eq 0 ] || \"vendor/bin/mozart\" compose",
"composer dump-autoload"
]
},
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true
}
},
"extra": {
"mozart": {
"dep_namespace": "Texty\\Dependencies\\",
"dep_directory": "/dependencies/",
"classmap_directory": "/dependencies/classes/",
"classmap_prefix": "Texty_",
"packages": [
"appsero/updater",
"appsero/client"
],
"excluded_packages": [
"psr/container"
],
"override_autoload": {
"google/apiclient": {
"classmap": [
"src/"
]
}
},
Comment on lines +53 to +71
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Mozart configuration needs directory adjustments and .gitignore updates

The verification revealed several issues that need attention:

  • The /dependencies/classes/ directory specified in Mozart config is missing
  • Neither /dependencies/ nor /dependencies/classes/ are listed in .gitignore
  • The existing /dependencies directory structure doesn't match Mozart's expected layout

Required actions:

  • Add /dependencies/ and /dependencies/classes/ to .gitignore
  • Create the /dependencies/classes/ directory to match Mozart configuration
  • Ensure the existing /dependencies/Appsero content aligns with the expected Mozart output structure
🔗 Analysis chain

Verify Mozart configuration alignment with project structure.

The Mozart configuration appears well-structured, but please ensure:

  1. The /dependencies/ and /dependencies/classes/ directories are gitignored
  2. The appsero/client and appsero/updater packages are compatible with namespace prefixing
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check .gitignore entries and directory structure
echo "Checking .gitignore entries:"
rg "dependencies/" .gitignore
rg "dependencies/classes/" .gitignore

# Verify Appsero package compatibility
echo "Checking Appsero package structure:"
rg -l "namespace\s+Appsero" vendor/appsero

Length of output: 315


Script:

#!/bin/bash
# Let's check if .gitignore exists and its content
echo "Checking if .gitignore exists:"
ls -la .gitignore

echo "\nChecking current .gitignore content:"
cat .gitignore

# Check if dependencies directories exist
echo "\nChecking dependencies directories:"
ls -la dependencies 2>/dev/null || echo "dependencies/ directory not found"
ls -la dependencies/classes 2>/dev/null || echo "dependencies/classes/ directory not found"

# Check composer.lock for actual package versions
echo "\nChecking if appsero packages are in composer.lock:"
if [ -f composer.lock ]; then
    rg -A 5 '"name":\s*"appsero/' composer.lock
else
    echo "composer.lock not found"
fi

Length of output: 1207

"delete_vendor_directories": true
}
}
}
Loading