Composer require branch name

后端 未结 2 888
既然无缘
既然无缘 2020-12-04 14:48

For example I want to require:

{
  \"repositories\": [
    {
      \"type\": \"git\",
      \"url\": \"https://github.com/google/google-api-php-client.git\"
         


        
2条回答
  •  猫巷女王i
    2020-12-04 15:21

    this will work :

    {
      "repositories": [
        {
          "type": "git",
          "url": "https://github.com/google/google-api-php-client.git"
        }
      ],
    
      "require": {
        "google/apiclient": "dev-BRANCH_NAME"
      }
    }
    

    so pattern is "dev-*", if you branch name is "bug-fix" then "dev-bug-fix"

    with command line :

    composer require google/apiclient:dev-BRANCH_NAME
    

提交回复
热议问题