rarst/release-belt
Composer 安装命令:
composer require rarst/release-belt
包简介
Composer repository for ZIPs
README 文档
README
Release Belt is a Composer repository, which serves to quickly integrate third–party non–Composer releases into Composer workflow. Once Release Belt is installed and you upload your zip files with their respective version number, Release Belt does the rest.
Given the following folder tree:
releases/wordpress-plugin/rarst/plugin.1.0.zip
It will serve the following Composer repository at /packages.json automagically:
{
"packages": {
"rarst/plugin": {
"1.0": {
"name": "rarst/plugin",
"version": "1.0",
"dist": {
"url": "http://example.com/rarst/plugin.1.0.zip",
"type": "zip"
},
"type": "wordpress-plugin",
"require": {
"composer/installers": "^1.5"
}
}
}
}
}
Installation
1. Install the project
Release Belt is a project type Composer package. It is recommended to use Git checkout to keep up with updates more easily.
There is a helper Composer script provided that tries to fetch latest stable version and performs Composer install.
Install
git clone https://github.com/Rarst/release-belt
cd release-belt
composer belt-update
Update
composer belt-update
2. Place release ZIPs into releases/ directory
The directory structure should be: releases/[type]/[vendor name]/[release zip file].
A [type] could be:
- a native Composer type (e.g.
libraryfor the default); - any type
composer/installerssupports (e.g.wordpress-plugin); - or completely arbitrary.
3. Configure a web server
The public/ directory should be used as web root and index.php in it as the file to handle requests.
Please refer to web server configuration in Slim documentation and/or your web hosting’s resources for setup specifics.
Visit home page and /packages.json in a web browser to check if it is working.
Use
Once Release Belt is installed you can add the repository to the composer.json of your projects.
Release Belt home page will automatically generate some composer.json boilerplate for you to use.
Configuration
You can configure Release Belt by creating a config/config.php file, which returns an array of options to override.
See config/configExample.php for the annotated example.
Authentication & permissions
Release Belt implements HTTP authentication to password protect your repository and control access to specific packages. You can configure it via users configuration option.
There is a bin/encodePassword.php command line helper included for hashing passwords:
>php bin/encodePassword.php foo $2y$10$3i9/lVd8UOFIJ6PAMFt8gu3/r5g0qeCJvoSlLCsvMTythye19F77a
If authentication is enabled, Release Belt home page will automatically generate auth.json boilerplate for you to use.
F.A.Q.
Why not Packagist/Satis?
Composer infrastructure is awesome, but it expects vendors that are willing to play nice with it.
Release Belt is a solution for unwilling vendors and it was faster and easier to build a dedicated solution from scratch.
Why not artifacts?
Composer artifacts require composer.json in them. This is for releases that don't even have that.
But is it web scale?
No.
License
MIT
rarst/release-belt 适用场景与选型建议
rarst/release-belt 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 103 次下载、GitHub Stars 达 176, 最近一次更新时间为 2014 年 11 月 26 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 rarst/release-belt 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 rarst/release-belt 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 103
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 177
- 点击次数: 20
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-11-26