karamel/console 问题修复 & 功能扩展

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

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

karamel/console

Composer 安装命令:

composer require karamel/console

包简介

console package for php

README 文档

README

kartizan is a command line for ‌‌php projects.
It provides a number of helpful commands for your use while developing your application

Installation

Installation is super-easy via Composer:

$ composer require karamel/console

After installing the package, use the following command to place the Cartesian file in the main root of your project

cp vendor/karamel/console/kartisan .

Inside this file are two define‍ named CONTROLLER_NAMESPACE and MODEL_NAMESPACE .

The value of these definitions determines the value of the namespace prefix to create the controller and model.

Note that placing these definitions is optional. If you do not use these definitions, the default value will not be considered for you and your controller and model will be created in the path that you enter when executing the command.

List of commands

  • make:controller : To create a controller
  • make:model : To create a model
  • serve : To run the server

Usage

create Controller

To create a ```controller``, just run the following command in the main root of the project

php kartisan make:controller ``controller-name``

sample :

php kartisan make:controller Panel/Blog/PostController

Executing the above command creates a controller called PostController in the path and namespace of the Panel/Blog .

create Model

To create a ```Model``, just run the following command in the main root of the project

php kartisan make:model  <model-name>

sample :

php kartisan make:model Model/Post

Executing the above command creates a model called PostController in the path and namespace of the Model .

Run the server

To run the server, just enter the following command in the terminal in the main project path .

php kartisan serve 

This command also takes the following desired parameter :
‍‍--t : Specifies the document root for the server to run. By default, the value of this folder is /public
--port : Specifies your preferred port to boot the server.

sample :

php kartisan serve --port=8081 --t=/public

统计信息

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

GitHub 信息

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

其他信息

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

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固