codeigniter4/tasks
Composer 安装命令:
composer require codeigniter4/tasks
包简介
Task Scheduler for CodeIgniter 4
README 文档
README
A task scheduler for CodeIgniter 4.
Installation
Install via Composer:
composer require codeigniter4/tasks
Migrate the database:
for Unix
php spark migrate -n CodeIgniter\\Settings
for Windows
php spark migrate -n CodeIgniter\Settings
Configuration
Publish the config file:
php spark tasks:publish
Defining tasks
Define your tasks in the init() method:
// app/Config/Tasks.php <?php namespace Config; use CodeIgniter\Tasks\Config\Tasks as BaseTasks; use CodeIgniter\Tasks\Scheduler; class Tasks extends BaseTasks { /** * Register any tasks within this method for the application. * * @param Scheduler $schedule */ public function init(Scheduler $schedule) { $schedule->command('demo:refresh --all')->mondays('11:00 pm'); } }
Docs
Read the full documentation: https://tasks.codeigniter.com
Contributing
We accept and encourage contributions from the community in any shape. It doesn't matter whether you can code, write documentation, or help find bugs, all contributions are welcome. See the CONTRIBUTING.md file for details.
统计信息
- 总下载量: 128.76k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 113
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-12-21