定制 cable8mm/db-to-markdown 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

cable8mm/db-to-markdown

最新稳定版本:v1.3.3

Composer 安装命令:

composer create-project cable8mm/db-to-markdown

包简介

DB to markdown generator

README 文档

README

code-style run-tests Packagist Version Packagist Downloads Packagist Dependency Version Packagist Dependency Version Packagist Stars Packagist License

This tool is specialized in generating Markdown files, particularly designed for creating Jekyll Markdown documents from a database. You can generate your own Markdown, such as Jekyll, Astro, Gatsby, or any other format you prefer.

We have provided the API Documentation on the web. For more information, please visit https://www.palgle.com/db-to-markdown/ ❤️

Features

  • Any schema can generate Markdown in any desired format
  • Effortlessly incorporate your custom mapper and command
  • Implement callback body and datetime functionality
  • Database testing is supported

Preview

Preview

Support & Tested

Versions PHP 8.0.2 PHP 8.1.* PHP 8.2.* PHP 8.3.*
Available

Installation

composer create-project cable8mm/db-to-markdown

Usage

Configure .env to connect to your own database. If .env configuration is not provided, SQLite connection is established.

bin/console seeding
# If `.env` configuration is not provided, seeding must be performed.

Database connection is established,

bin/console create-md
# Convert the database to markdown files in the dist folder.

bin/console create-jekyll
# Convert the database to markdown files suitable for Jekyll in the dist folder.

bin/console clean
# Clear the contents of the dist folder.

How to Develop Custom Commands

  1. Please fill in the database connection information in the .env file. You can verify it by using the composer test command.
  2. You can create a mapping class in the src/Mappers/ folder for input and a format class in the src/Formats for output.
  3. Finally, you can create a command of your choice in the src/Command folder.

I have already prepared the mapper, format class, and command.

Formatting

composer lint
# Modify all files to comply with the PSR-12.

composer inspect
# Inspect all files to ensure compliance with PSR-12.

Test

It uses the built-in SQLite database, not your own database. It will never cause harm to your data. You don't need to worry about that.

composer test

License

The DB to markdown project is open-sourced software licensed under the MIT license.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-03-02