handmade-medium/console-progress-bar 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

handmade-medium/console-progress-bar

Composer 安装命令:

composer require handmade-medium/console-progress-bar

包简介

PHP Console Progress Bar

README 文档

README

Provides a progress bar for console applications

  • ConsoleProgressBar = Generic PHP Cli Progress Bar
  • DrushProgressBar = Customized for use in a Drush console application

Usage

// width of the left title column
$colWidth = 50;
// size of bar
$size = ConsoleProgressBar::SIZE_MEDIUM;
// max value of loop
$max = 100;
// text for column
$text = "Test";
// init
$progressBar = new ConsoleProgressBar($max, $size, $text, $colWidth);
// loop
for($x=1;$x<=$max;$x++) {
$progressBar->showProgress($x);
}
// end
$progressBar->showComplete();

Examples

see examples/consoleExample.php

> php examples/consoleExample.php
Example Spinner      [X] 100%
Example Small Bar    [=========================] 100%
Example Medium Bar   [==================================================] 100%
Example Large Bar    [====================================================================================================] 100%
Custom Bar           [##################################################] 100%
Custom Spinner       [X] 100%

v1.0.2

  • Added Tests for Drush 6 .. 8
  • Added Test for Console
  • Added Custom bar and Custom Spinner options
  • Fixed Large Bar bug - do not exceed viewport width

v1.0

  • Initial Release

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: GPL-3.0
  • 更新时间: 2017-05-02

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固