ezar101/litedocs
最新稳定版本:v1.0.4
Composer 安装命令:
composer require ezar101/litedocs
包简介
A lightweight static site generator.
README 文档
README
LiteDocs
LiteDocs is a modern, lightweight, and blazing fast static site generator written in PHP 8.4+.
It is designed to build beautiful documentation sites from Markdown files with zero configuration.
📚 Read the Official Documentation
✨ Features
- ⚡ Zero Config: Works out of the box with sensible defaults.
- 🎨 Theming: Powerful templating engine based on Twig. Includes a modern "Lite" theme.
- 🔌 Plugins: Extensible architecture using Symfony EventDispatcher.
- 🌍 Multilingual: Native support for internationalization (i18n).
- 🔍 Search: Built-in client-side search engine (no external services required).
- 🛠 Developer Friendly: 100% PHP, easy to override and extend.
🚀 Installation
Option 1: Standalone PHAR (Recommended)
You can download the single executable file from the Releases Page.
wget https://github.com/Ezar101/LiteDocs/releases/latest/download/litedocs.phar chmod +x litedocs.phar sudo mv litedocs.phar /usr/local/bin/litedocs
Option 2: Via Composer
composer global require Ezar101/litedocs
🏁 Quick Start
-
Initialize a new project Create a litedocs.yml file and a docs/ folder with some markdown files.
-
Build the site Run the build command in your project directory:
litedocs build
-
Development Mode (Optional) To automatically rebuild the site whenever you change a file:
litedocs watch
Tip: Open a second terminal and run
php -S localhost:8000 -t siteto view your changes live. -
Enjoy Your static site is generated in the site/ directory, ready to be deployed to GitHub Pages, Vercel, or Netlify.
⚙️ Configuration
Create a litedocs.yml file at the root of your project:
site_name: "My Awesome Docs" docs_dir: "docs" site_dir: "site" # Enable multilingual support languages: en: English fr: Français # Theme configuration theme: name: lite # Import navigation and plugins nav: "config/nav.yml" plugins: "config/plugins.yml"
🤝 Contributing
Contributions are welcome! We enforce high code quality standards to keep the project maintainable.
Requirements
- PHP 8.4+
- Composer
Development Workflow
-
Fork the repository and create a new branch.
-
Install dependencies:
composer install
-
Write Tests: We use Pest PHP.
composer test -
Analyze Code: Ensure static analysis passes.
composer analyse
-
Fix Style: Format your code to PSR-12 standards.
composer lint # Check composer fix # Auto-fix
-
Submit a Pull Request.
Note: Our CI pipeline will automatically block any PR that does not pass tests or static analysis.
📄 License
LiteDocs is open-sourced software licensed under the MIT license.
统计信息
- 总下载量: 0
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-12-07
