Skip to main content

A CLI tool for generating and managing web projects using Flet.

Project description

PyFlet CLI

PyFlet CLI is a command-line interface tool designed to facilitate the creation and management of Flet web projects. It automates the setup process and provides essential commands for project initialization and user management.

Installation

To install PyFlet CLI, use the following command:

pip install pyflet

Usage

Run the CLI using:

pyflet [COMMAND] [OPTIONS]

Commands

1. Create a Flet Web Project

pyflet create-flet-web <project_name>

Creates a new Flet web project using a predefined template.

2. Initialize a Project

pyflet init-project --reload <true/false> --project_path <path> --platform <web/android/ios>
  • --reload: Automatically reload the project on changes (default: true).
  • --project_path: Path to the main Python file (default: main.py).
  • --platform: Target platform (default: web).

3. Create a Superuser

pyflet createsuperuser

Prompts the user to enter credentials and creates a superuser in the database.

4. Get Support

pyflet support

Displays support information and the author's YouTube channel.

Configuration

Database Management

This CLI interacts with SQLite databases using the manage_sql library. The superuser creation command inserts data into the users table.

Cloning Project Templates

The CLI clones project templates from the repository:

https://github.com/webtechmoz/pyflet-models.git

It copies template files to the new project directory while replacing placeholders.

Logging

The CLI provides informative logs in different levels:

  • info: General information (blue)
  • success: Successful operations (green)
  • warning: Potential issues (yellow)
  • error: Errors encountered (red)

Contributing

Feel free to contribute to this project by submitting issues or pull requests on GitHub.

License

This project is licensed under the MIT License.

Author

Created by DevPythonMZ.

📢 Subscribe to the YouTube channel: @devpythonMZ

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyflet-0.3.1.tar.gz (5.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyflet-0.3.1-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file pyflet-0.3.1.tar.gz.

File metadata

  • Download URL: pyflet-0.3.1.tar.gz
  • Upload date:
  • Size: 5.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for pyflet-0.3.1.tar.gz
Algorithm Hash digest
SHA256 3500fdecf3350fcde11f1720760b8215e4aafde78098b787323cdd384f721181
MD5 39d16c04b11c848145f88a4d1662342e
BLAKE2b-256 0151dfecb88694be8725653715e8949b42759b15cf2a5e64a0db86aa59452c36

See more details on using hashes here.

File details

Details for the file pyflet-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: pyflet-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for pyflet-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 907bf46f7d53391e2b650cdb5660f82c593a950325cff62fd29fa8bbc8001669
MD5 f447658b65b91d61bd9dcc52d9005db3
BLAKE2b-256 879cd4bfd31c6f8c9ef24c0eed5be31ba3d8ccedef4729763b8b78488624d459

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page