定制 dpp/composer-plugin 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

dpp/composer-plugin

最新稳定版本:1.0.0-beta13

Composer 安装命令:

composer require dpp/composer-plugin

包简介

Composer plugin for integration with the Drupal Project Platform

README 文档

README

This plugin adds the ability to use the DPP package manager.

Installation

The plugin needs to be installed globally, because it needs to be present before composer resolves the dependencies.

composer global config repositories.dpp-composer-plugin vcs https://gitlab.burdaverlag.dev/thunder/dpp-composer-plugin.git
composer global require dpp/composer-plugin

Configuration

Onboard existing project via command

You can run the custom onboard command to configure your existing project.

composer dpp-onboard

It automatically updates your composer.json so your project is set up for DPP and finally performs composer update to make sure all dependencies are supported.

Options

The command lets you set your own DPP base project git url

composer dpp-onboard --dpp-base-project-git-url git@gitlab.burdaverlag.dev:dpp/DPP-Base-Project.git

and your preferred DPP version constraint

composer dpp-onboard --dpp-version ^2.0

Manually configure your DPP project

Add the git url of your DPP base project to your composer.json extra section.

"extra": {
    "dpp-base-project-git-url": "git@gitlab.burdaverlag.dev:dpp/DPP-Base-Project.git"
},

Or set the environment variable

COMPOSER_DPP_BASE_PROJECT_GIT_URL="git@gitlab.burdaverlag.dev:dpp/DPP-Base-Project.git"

Also it's recommended to disable the packagist.org repo.

"repositories": [
    {
        "packagist.org": false
    }
]

Usage

You can now set the dpp version constraint in your composer.json.

  "require": {
    "dpp/version": "^1.0.0"
  },

All your other required packages will be resolved by the DPP package manager.

Dev Mode

To create a composer.dev.json with access to all packagist.org packages run:

composer dpp-create-dev-json

To use the composer.dev.json file run composer commands like

COMPOSER=./composer.json.dev composer <command>

Development

Create a new directory and add a composer.json file with the following content:

{
  "name": "dpp/dpp-project",
  "type": "project",
  "repositories": {
    "dpp/composer-plugin": {
      "type": "path",
      "url": "../plugin"
    }
  },
  "require": {
    "dpp/composer-plugin": "^1",
    "cweagans/composer-patches": "*"
  },
  "extra": {
    "enable-patching": true,
    "dpp-base-project-git-url": "git@gitlab.burdaverlag.dev:dpp/DPP-Base-Project.git"
  },
  "config": {
    "allow-plugins": {
      "dpp/composer-plugin": true
    }
  }
}

Change the url in the repositories section to the path to the plugin directory.

Then run composer install to install the plugin.

After that, you can run composer require dpp/version to test the plugin.

统计信息

  • 总下载量: 248.61k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 未知

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固