4

I've been trying to validate my extension before submit it to Magento Marketplace.

I've installed MEQP using composer.

$ composer create-project --repository=https://repo.magento.com magento/marketplace-eqp magento-coding-standard

But when I am trying to execute below commands as per Magento says it gives me error in my console.

Note: Currently I am on localhost with Xampp on windows OS.

1). Navigated to magento-coding-standard directory to my Magento2 root.

2). C:\xampp\htdocs\m2fresh\magento-coding-standard>cd vendor/bin/phpcs C:\xampp\htd ocs\m2fresh\app\code\Vendor\Module\ --standard=MEQP2

It giving me error like below.

The filename, directory name, or volume label syntax is incorrect

Any suggestion?

2

I think it creates an Issue because you are passing cd(change directory) in your command. try to execute without it. And one more thing If you are using Window OS then you need to make sure about slash (forward / or backward ).

Try with below command,

C:\xampp\htdocs\m2fresh\magento-coding-standard\vendor\bin\phpcs C:\xampp\htdocs\m2fresh\app\code\Vendor\Module\ --standard=MEQP2

  • 1
    I did try than now error changes to vendor isn't recognized as an internal or external command. :( No Luck, Same Issue. – Vivek Apr 9 '18 at 6:52
  • See my edit and make sure about slash @LazyCoder – Keyur Shah Apr 9 '18 at 6:55
  • One more thing is there any log generated expect console, I can't check all warnings in it ? – Vivek Apr 9 '18 at 7:06
  • 1
    I am not sure about but If you want to submit this extension to marketplace then you need to pass one argument --severity=10 and IF you are getting any error then you need to resolve this error. And If you want to solve error automatic then you need to pass phpcbf instead of phpcs – Keyur Shah Apr 9 '18 at 7:10
2

@LazyCoder Yes, You can generate log in an external file.

For that, you need to pass one argument (> Filename.log) with the command.

Example:

C:\xampp\htdocs\m2fresh\magento-coding-standard\vendor\bin\phpcs
C:\xampp\htdocs\m2fresh\app\code\Vendor\Module\ --standard=MEQP2 > test.log

The file is created in the path where you apply the command.

  • 1
    If this answer is really helpful to you then please accept the answer.So it will be helpful for others. – Emipro Technologies Pvt. Ltd. Apr 9 '18 at 10:09
  • 1
    Both answers helpful can't divide accept answer into 2 parts :) – Vivek Apr 9 '18 at 10:36
  • It is require to change path any other file inside "Magento_Root/Vendor/bin" ? – Sanjay Gohil Apr 16 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.