Skip to content

你好,能将这个包放到https://packagist.org/吗 #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Gelaku opened this issue Dec 2, 2020 · 3 comments
Open

你好,能将这个包放到https://packagist.org/吗 #9

Gelaku opened this issue Dec 2, 2020 · 3 comments

Comments

@Gelaku
Copy link

Gelaku commented Dec 2, 2020

你好,能将这个包放到https://packagist.org/吗

@Gelaku
Copy link
Author

Gelaku commented Dec 2, 2020

这样既可以用:composer require ganlvtech/php-enphp-decoder:^1.4安装了

@ganlvtech
Copy link
Owner

ganlvtech commented Dec 3, 2020

我其实不希望这个包被广泛使用,等待那些有缘人自己来探索这些边缘地带。

不过我可以提供一个解决方法,Composer 支持直接从 git 仓库拉取代码,如果你的电脑已经安装了 git 命令行的话。

手动在 require 中加入 ganlvtech/php-enphp-decoder:^1.4,然后再额外添加一个 repositories 作为代码源就行啦。

{
    "repositories": [
        {
            "type": "git",
            "url": "https://github.com/ganlvtech/php-enphp-decoder.git"
        }
    ],
    "require": {
        "ganlvtech/php-enphp-decoder": "^1.4"
    }
}

注意,不要让你的 vendor 目录可以直接通过 web 服务访问到,因为 bin public tests 目录都是有可执行的代码的,只有 src 是功能代码,不能直接被执行。

如果你仍然觉得麻烦,可以自己上传一份到自己的 packagist 用户名下。

@Gelaku
Copy link
Author

Gelaku commented Dec 4, 2020

三克油

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants