承接 mathiasverraes/uptodocs 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

mathiasverraes/uptodocs

Composer 安装命令:

composer require --dev mathiasverraes/uptodocs

包简介

UpToDocs scans a Markdown file for PHP code blocks, and executes each one in a separate process. Include this in your CI workflows, to make sure your documentation is always up to date with your code.

README 文档

README

UpToDocs scans a Markdown file for PHP code blocks, and executes each one in a separate process.

Include this in your CI workflows, to make sure your documentation is always up to date with your code.

Usage

composer require --dev mathiasverraes/uptodocs

CLI:

vendor/bin/uptodocs run [options] [--] <markdownFile>

Arguments:
  markdownFile          Markdown file to run.

Options:
  -b, --before=BEFORE   A PHP file to run before each code block. 
                        Useful for imports and other setup code.
  -a, --after=AFTER     A PHP file to run after each code block. 
                        Useful for cleanup, and for running assertions.

In your code:

<?php
$upToDocs = new Verraes\UpToDocs\UpToDocs();
$result = $upToDocs->run("README.md"); // bool

Example

You can try it on the Markdown file in the sample directory:

./uptodocs run sample/docs.md --before sample/before.php

Output:

The following code block in /Users/mathias/workspace/php/uptodocs/sample/docs.md:16 failed.
<?php
$v = multiplyy(10,2);

PHP Fatal error:  Uncaught Error: Call to undefined function multiplyy() in Standard input code:11
Stack trace:
#0 {main}
  thrown in Standard input code on line 11

UpToDocs discovered a typo in our sample code. Oops!

统计信息

  • 总下载量: 1.06k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 61
  • 点击次数: 0
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-06-11

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固