承接 hungthai1401/grumphp-pint-task 相关项目开发

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

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

hungthai1401/grumphp-pint-task

最新稳定版本:v0.0.2

Composer 安装命令:

composer require hungthai1401/grumphp-pint-task

包简介

Laravel Pint task runner from GrumPHP

README 文档

README

This package extends GrumPHP with a task that runs Laravel Pint for your Laravel projects.

Installation

The easiest way to install this package is through composer:

composer require --dev hungthai1401/grumphp-pint-task

Config

Add the extension loader to your grumphp.yml or grumphp.yml.dist. The task lives under the laravel_pint namespace and has following configurable parameters:

grumphp:
  tasks:
    laravel_pint:
      config: 'pint.json'
      files_on_pre_commit: false
      paths: ['src']
  extensions:
    - HT\GrumPhpPintTask\ExtensionLoader

By default, this won't update your code, you need to do it manually.

config

Default: 'pint.json'

If you want to use a different config file than the default pint.json, you can specify your custom config file location with this option.

files_on_pre_commit

Default: false

This option makes it possible to use the changed files as paths during pre-commits. It will use the paths option to make sure only committed files that match the path are validated.

paths

Default: []

Can only be used when files_on_pre_commit=false

If you want to run on particular directories only, specify it with this option.

Sample Laravel Pint configuration

Create pint.json in your project root and configure as follows. This example file I am using for my Laravel project. Also you no need to set all these settings, please add or remove as per your requirements.

{
  "preset": "laravel",
  "rules": {
    "concat_space": {
      "spacing": "one"
    },
    "fully_qualified_strict_types": true,
    "global_namespace_import": {
      "import_constants": true,
      "import_functions": true,
      "import_classes": true
    }
  }
}

Please visit Laravel Pint for more configuration examples.

Uninstall

If you want to uninstall this extension remove configuration files first: pint.json from your application, then remove package:

composer remove hungthai1401/grumphp-pint-task

Changelog

Please see CHANGELOG for more information on what has changed recently.

License

The MIT License (MIT). Please see License File for more information.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-11-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固