A simple Scraper template creator
Project description
Flask Ignite
A simple Flask app creator that automatically generates a basic Flask project structure including models, routes, services, configuration, and more.
Getting Started
This repository contains a utility package that, once installed, provides a CLI command to create a Flask project structure automatically. The command is registered as a console script named flask-admin.
Prerequisites
- Python 3.7 or higher
- Flask
- Flask-SQLAlchemy
- Flask-Migrate
- python-dotenv
Setup and Usage
-
Clone the Repository
Clone this repository to your local machine.
-
Install the Package
From the root of the repository, install the package locally:
pip install flask-ignite
-
Run the Project Setup Command
Execute the following command to generate the Flask project structure:
flask-ignite --project <your_project_name> # defaults to flask_app
This will create a project structure similar to the following:
- flask_app/
- app/
- models/
__init__.pyuser.pypost.py
- routes/
__init__.pyuser_routes.pypost_routes.py
- services/
__init__.pyuser_service.py
- config/
__init__.pysettings.py
extensions.py__init__.py
- models/
- migrations/
.envconfig.pyrequirements.txtwsgi.pyrun.py
- app/
- flask_app/
-
Next Steps
After generating the project, follow these steps:
-
Navigate into the generated project directory:
cd flask_app
-
Create a virtual environment:
python -m venv venv
-
Activate the virtual environment:
- Windows:
venv\Scripts\activate
- Mac/Linux:
source venv/bin/activate
- Windows:
-
Install the project dependencies:
pip install -r requirements.txt
-
Initialize the database:
flask db init && flask db migrate -m "Initial migration" && flask db upgrade
-
Run the app:
python run.py
-
Project Structure Overview
- app/models: Contains database models (e.g.,
UserandPostdefined inuser.pyandpost.py). - app/routes: Defines routes using Blueprints for handling API endpoints (in
user_routes.pyandpost_routes.py). - app/services: Holds service functions for data manipulation or retrieval (in
user_service.py). - app/config: Stores configuration settings and environment-specific variables (in
settings.py). - app/extensions.py: Initializes Flask extensions like SQLAlchemy and Migrate.
- app/init.py: Creates and configures the Flask application.
License
This project is licensed under the MIT License.
Author
Nahom D
Email: nahom@nahom.eu.org
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file scraper_ignite-0.1.0.tar.gz.
File metadata
- Download URL: scraper_ignite-0.1.0.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b879452d53d8d29c41728bac96dd884d5608263ae56e8fe8f7bcd43c84981b51
|
|
| MD5 |
93eb95577fe9f6d0eee778638a2afea1
|
|
| BLAKE2b-256 |
11359cb37174e617d8259231553ae8f26141d3675ee47ba006159f7b3a0b124c
|
File details
Details for the file scraper_ignite-0.1.0-py3-none-any.whl.
File metadata
- Download URL: scraper_ignite-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ba97fba1bd467c8738170753a37c037e9ed437ad235c57af6c31e0459d59aba
|
|
| MD5 |
e8b3b30b5070a697204b03998115d43f
|
|
| BLAKE2b-256 |
49d29c37f288447a0a96b4d4e806bf219c7aee72eb834409e8ad3428ef23f6fd
|