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.0.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.0-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: pyflet-0.3.0.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.0.tar.gz
Algorithm Hash digest
SHA256 4c2c8590d8265996f49dff1799833ad7d6ce6d8e22a2aee5091eb21b2002f576
MD5 94424a1304fc56573dc0808509cfcbbb
BLAKE2b-256 ad28d1a6aec9434ba33ba891b43c408fb5414cc441620674ca788076b6185491

See more details on using hashes here.

File details

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

File metadata

  • Download URL: pyflet-0.3.0-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.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4e742da811d115f9b37dfd5d0515c01f144aae2efd82e49d7b42d2c05a55142c
MD5 e9f2dc5c59bdc4cf77200fb9280e1706
BLAKE2b-256 feed323daf0900558393619e367607ac9bf74f730df086ea4d8db1b91e763edb

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