https://github.com/sxhxliang/fastapi-cli
fastapi-cli
https://github.com/sxhxliang/fastapi-cli
curl fastapi fastapi-template
Last synced: 4 months ago
JSON representation
fastapi-cli
- Host: GitHub
- URL: https://github.com/sxhxliang/fastapi-cli
- Owner: sxhxliang
- License: mit
- Created: 2021-04-01T04:58:44.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-04-02T02:47:48.000Z (almost 4 years ago)
- Last Synced: 2025-08-28T19:06:24.843Z (5 months ago)
- Topics: curl, fastapi, fastapi-template
- Language: Python
- Homepage:
- Size: 800 KB
- Stars: 20
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
Project generator and manager for FastAPI.
---
**Source Code**: View it on [Github](https://github.com/sxhxliang/fastapi-cli)
---
## Features 🚀
* #### Creates customizable **project boilerplate.**
* #### Creates customizable **app boilerplate.**
* #### Handles the project structuring for you.
* #### Optional Dockerfile generation.
* #### Optional docker-compose generation for your project needs.
* #### Optional pre-commit hook generation.
## Installation 📌
* Prerequisites
* Python 3.6 +
Manage FastAPI can be installed by running
```python
pip3 install git+https://github.com/sxhxliang/fastapi-cli
# or
git clone https://github.com/sxhxliang/fastapi-cli
cd fastapi-cli && python3 setup.py develop
```
## Getting started 🎈
Easiest way to start is using the defaults:
```bash
fastapi startproject [name]
```
But there is an **interactive** mode!
```bash
fastapi startproject [name] --interactive
```
## Command line options 🧰
Manage FastAPI provides three different commands.
You can list them with
```bash
fastapi --help
```

The idea is to have a highly customizable CLI, but at the same time a simple interface for new users. You can see the available options for `startproject` running `fastapi startproject --help`:

The other commands are already available but the current implementation is too shallow. More details about `startapp` and `run` commands will be provided once they have more functionalities, at the moment you can run `startapp` by just:
```bash
fastapi startapp {name}
```
On the other hand, the `run` command expects you to have a `startproject` structure:
```bash
fastapi run
```
## License
This project is licensed under the terms of the MIT license.