How do I make a composer.json script accept flagsHow do you pass an argument to a composer script from the command line?How to create a Symbolic link to PHPUnit?Autoloading classes in PHPUnit using Composer and autoload.phpComposer install/update failingSymfony 2 -> Composer and CloudControlComposer is not copying on the specified bin-dir directoryInstall CakePHP's DebugKit with composerfopen error when installing Composer for PHP (Windows 7)Composer fails executing app/console cache:clear on symfony 3PHPUnit composer installation on WAMP not workingphp bin/console symfony commands give a fatal errorPHPUnit Tests can't read Tests

Basis and cardinality

What is the meaning of "it" in "as luck would have it"?

Why doesn't SpaceX land boosters in Africa?

Two palindromes are not enough

Rear derailleur got caught in the spokes, what could be a root cause

What would you need merely the term "collection" for pitches, but not "scale"?

What was the first science fiction or fantasy multiple choice book?

Are you required to spend hit dice to take a short rest?

Disk usage confusion: 10G missing on Linux home partition on SSD

What is this fluorinated organic substance?

Why would Dementors torture a Death Eater if they are loyal to Voldemort?

iMac 2019: Can I mix the old modules with the new ones when upgrading RAM?

Where to connect the fuse and why?

Cat files in subfolders in order given by a list

How can this fractal shape perfectly cover a certain platonic solid?

Tricolour nonogram

Chandra exiles a card, I play it, it gets exiled again

My mom helped me cosign a car and now she wants to take it

Which high-degree derivatives play an essential role?

How soon after takeoff can you recline your airplane seat?

What's the point of stochastic volatiliy models if you can use local volatility?

A* pathfinding algorithm too slow

Why isn't UDP with reliability (implemented at Application layer) a substitute of TCP?

I agreed to cancel a long-planned vacation (with travel costs) due to project deadlines, but now the timeline has all changed again



How do I make a composer.json script accept flags


How do you pass an argument to a composer script from the command line?How to create a Symbolic link to PHPUnit?Autoloading classes in PHPUnit using Composer and autoload.phpComposer install/update failingSymfony 2 -> Composer and CloudControlComposer is not copying on the specified bin-dir directoryInstall CakePHP's DebugKit with composerfopen error when installing Composer for PHP (Windows 7)Composer fails executing app/console cache:clear on symfony 3PHPUnit composer installation on WAMP not workingphp bin/console symfony commands give a fatal errorPHPUnit Tests can't read Tests













0















I can't add a --filter argument to my composer.json script.



I've been reading up the docs but I can't seem to figure it out.



I have the following script in my composer.json



"scripts": 
"test": [
".\vendor\bin\phpunit"
]
,


But I can't send any --filters with it like:



$ composer test --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


This renders the following error:



[SymfonyComponentConsoleExceptionRuntimeException] 
The "--filter" option does not exist.


Any idea how I can make the script accept the --filter argument?



I want to be able to run it quicker then always typing



.\vendor\bin\phpunit









share|improve this question



















  • 3





    Possible duplicate of How do you pass an argument to a composer script from the command line?

    – Daniel W.
    Mar 25 at 16:30











  • Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

    – ArneDB
    Mar 25 at 16:32












  • You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

    – Daniel W.
    Mar 25 at 16:32












  • Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

    – ArneDB
    Mar 25 at 16:36















0















I can't add a --filter argument to my composer.json script.



I've been reading up the docs but I can't seem to figure it out.



I have the following script in my composer.json



"scripts": 
"test": [
".\vendor\bin\phpunit"
]
,


But I can't send any --filters with it like:



$ composer test --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


This renders the following error:



[SymfonyComponentConsoleExceptionRuntimeException] 
The "--filter" option does not exist.


Any idea how I can make the script accept the --filter argument?



I want to be able to run it quicker then always typing



.\vendor\bin\phpunit









share|improve this question



















  • 3





    Possible duplicate of How do you pass an argument to a composer script from the command line?

    – Daniel W.
    Mar 25 at 16:30











  • Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

    – ArneDB
    Mar 25 at 16:32












  • You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

    – Daniel W.
    Mar 25 at 16:32












  • Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

    – ArneDB
    Mar 25 at 16:36













0












0








0








I can't add a --filter argument to my composer.json script.



I've been reading up the docs but I can't seem to figure it out.



I have the following script in my composer.json



"scripts": 
"test": [
".\vendor\bin\phpunit"
]
,


But I can't send any --filters with it like:



$ composer test --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


This renders the following error:



[SymfonyComponentConsoleExceptionRuntimeException] 
The "--filter" option does not exist.


Any idea how I can make the script accept the --filter argument?



I want to be able to run it quicker then always typing



.\vendor\bin\phpunit









share|improve this question
















I can't add a --filter argument to my composer.json script.



I've been reading up the docs but I can't seem to figure it out.



I have the following script in my composer.json



"scripts": 
"test": [
".\vendor\bin\phpunit"
]
,


But I can't send any --filters with it like:



$ composer test --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


This renders the following error:



[SymfonyComponentConsoleExceptionRuntimeException] 
The "--filter" option does not exist.


Any idea how I can make the script accept the --filter argument?



I want to be able to run it quicker then always typing



.\vendor\bin\phpunit






composer-php






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 25 at 16:39









vaxquis

8,0805 gold badges40 silver badges58 bronze badges




8,0805 gold badges40 silver badges58 bronze badges










asked Mar 25 at 16:28









ArneDBArneDB

84 bronze badges




84 bronze badges







  • 3





    Possible duplicate of How do you pass an argument to a composer script from the command line?

    – Daniel W.
    Mar 25 at 16:30











  • Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

    – ArneDB
    Mar 25 at 16:32












  • You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

    – Daniel W.
    Mar 25 at 16:32












  • Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

    – ArneDB
    Mar 25 at 16:36












  • 3





    Possible duplicate of How do you pass an argument to a composer script from the command line?

    – Daniel W.
    Mar 25 at 16:30











  • Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

    – ArneDB
    Mar 25 at 16:32












  • You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

    – Daniel W.
    Mar 25 at 16:32












  • Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

    – ArneDB
    Mar 25 at 16:36







3




3





Possible duplicate of How do you pass an argument to a composer script from the command line?

– Daniel W.
Mar 25 at 16:30





Possible duplicate of How do you pass an argument to a composer script from the command line?

– Daniel W.
Mar 25 at 16:30













Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

– ArneDB
Mar 25 at 16:32






Oh it's called an 'Argument', not a 'flag', that's why I wasn't getting decent search results on here and google. Thanks for your help!

– ArneDB
Mar 25 at 16:32














You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

– Daniel W.
Mar 25 at 16:32






You're welcome! A flag has no value! Flags are either set or not set. Arguments or parameters can have values :-)

– Daniel W.
Mar 25 at 16:32














Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

– ArneDB
Mar 25 at 16:36





Alright thanks! I updated my original question with the solution I found in your link! Thank you very much

– ArneDB
Mar 25 at 16:36










1 Answer
1






active

oldest

votes


















0














The key here is reading carefully the docs. In docs there is:




Similar to the run-script command you can give additional arguments to scripts, e.g. composer test -- --filter will pass --filter along to the phpunit script.




So to pass --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP you should in fact run:



composer test -- --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


so you should use here additional -- before specifying arguments that you want to pass.



Of course in this case the solution you search might be much simpler. You could just consider creating symbolic link to do this.






share|improve this answer






















    Your Answer






    StackExchange.ifUsing("editor", function ()
    StackExchange.using("externalEditor", function ()
    StackExchange.using("snippets", function ()
    StackExchange.snippets.init();
    );
    );
    , "code-snippets");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "1"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55342355%2fhow-do-i-make-a-composer-json-script-accept-flags%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    The key here is reading carefully the docs. In docs there is:




    Similar to the run-script command you can give additional arguments to scripts, e.g. composer test -- --filter will pass --filter along to the phpunit script.




    So to pass --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP you should in fact run:



    composer test -- --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


    so you should use here additional -- before specifying arguments that you want to pass.



    Of course in this case the solution you search might be much simpler. You could just consider creating symbolic link to do this.






    share|improve this answer



























      0














      The key here is reading carefully the docs. In docs there is:




      Similar to the run-script command you can give additional arguments to scripts, e.g. composer test -- --filter will pass --filter along to the phpunit script.




      So to pass --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP you should in fact run:



      composer test -- --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


      so you should use here additional -- before specifying arguments that you want to pass.



      Of course in this case the solution you search might be much simpler. You could just consider creating symbolic link to do this.






      share|improve this answer

























        0












        0








        0







        The key here is reading carefully the docs. In docs there is:




        Similar to the run-script command you can give additional arguments to scripts, e.g. composer test -- --filter will pass --filter along to the phpunit script.




        So to pass --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP you should in fact run:



        composer test -- --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


        so you should use here additional -- before specifying arguments that you want to pass.



        Of course in this case the solution you search might be much simpler. You could just consider creating symbolic link to do this.






        share|improve this answer













        The key here is reading carefully the docs. In docs there is:




        Similar to the run-script command you can give additional arguments to scripts, e.g. composer test -- --filter will pass --filter along to the phpunit script.




        So to pass --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP you should in fact run:



        composer test -- --filter pigeon_ringnumber_cant_be_more_then_9_chars_for_BE_NL_ESP


        so you should use here additional -- before specifying arguments that you want to pass.



        Of course in this case the solution you search might be much simpler. You could just consider creating symbolic link to do this.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Mar 25 at 19:28









        Marcin NabiałekMarcin Nabiałek

        76.3k28 gold badges166 silver badges206 bronze badges




        76.3k28 gold badges166 silver badges206 bronze badges
















            Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.







            Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.



















            draft saved

            draft discarded
















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55342355%2fhow-do-i-make-a-composer-json-script-accept-flags%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

            SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

            은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현