自己写了一个composer包,但是安装报错,如何解决?

源码
packages

但是,当我安装的时候报错,请问如何解决,顺便说下,我使用的composer镜像是这个

vagrant@homestead:~/Code/Awbeci3.2$ composer require awbeci/aliyun-dm


  [InvalidArgumentException]
  Could not find package awbeci/aliyun-dm at any version for your minimum-stability (stable). Check the p
  ackage spelling or your minimum-stability


require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]...
阅读 5k
4 个回答

clipboard.png

看图, 你这个git库, 只有master分支, 所以你安装的时候要指定安装分支, 命令如下 :

composer require awbeci/aliyun-dm:dev-master

如果你在git库了指定了类似 v-1.0.0 1.0.0 这种tag, 那么你直接安装才可以正常工作.

你的包没有最低的稳定版本。
可以通过这个网址 https://packagist.org/package... 的右边的版本列表看出来。

如果非要安装的话可以 composer require awbeci/aliyun-dm dev-master 这么安装

git tag v1.0.0
git push origin --tags

始终包这个错,请问是怎么回事啊

λ composer require zk/getpic-for-laravel dev-master
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

Problem 1

- The requested package zk/getpic-for-laravel could not be found in any version, there may be a typo in the package name.

Potential causes:

  • A typo in the package name
  • The package is not available in a stable-enough version according to your minimum-stability setting
    see https://getcomposer.org/doc/0... for more details.

Read https://getcomposer.org/doc/a... for further common problems.

Installation failed, reverting ./composer.json to its original content.

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
1 篇内容引用
宣传栏