byteplus/branch-name-display
最新稳定版本:v1.0.0
Composer 安装命令:
composer require byteplus/branch-name-display
包简介
Git branch name on your Laravel application
README 文档
README
Overview
This package allows you to display the current Git branch name on your Laravel application. It is especially useful for development and staging environments.
Installation
To install the package, run the following command:
composer require byteplus/branch-name-display --dev
Configuration
In your .env file, add the following line to control the visibility of the branch name:
DISPLAY_BRANCH_NAME=true
This will enable the branch name display only for local and staging environments by default.
Publishing Assets
It is required to published the CSS file.
php artisan vendor:publish --tag=public
Publish the view file is optional.
php artisan vendor:publish --tag=views
Feel free to customize them as needed.
Customization
The appearance of the branch name display can be customized by modifying the published CSS file located at:
public/css/branch-name-display.css
Usage
To use the branch name display, add the Blade directive right after the opening tag in your layouts.app file:
@conditionalBranchNameDisplay
This will ensure the branch name is displayed according to your configuration settings.
Note: If you don't see the changes immediately, you may need to clear the cache by running the following command:
php artisan view:clear
php artisan cache:clear
Author
Byteplus
mail@3design-bg.com
License
This package is licensed under the MIT License.
统计信息
- 总下载量: 14
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-06-26