|
1 | 1 | # JsonDB Project
|
2 | 2 |
|
| 3 | +<p align="center"> |
| 4 | + <img src="./assets/logo.png" alt="Logo" height="128px"> |
| 5 | +</p> |
| 6 | + |
| 7 | +<p align="center"> |
| 8 | + <img src="https://img.shields.io/badge/python-%2314354C.svg?&style=for-the-badge&logo=python&logoColor=white"/> |
| 9 | + <img src="https://img.shields.io/badge/json-%23000000.svg?&style=for-the-badge&logo=json&logoColor=white"/> |
| 10 | +</p> |
| 11 | + |
3 | 12 | The JsonDB Project provides a lightweight, file-based database system, designed to make data storage and retrieval simple and intuitive. Built in Python, it leverages the versatility of JSON for data manipulation, making it an ideal solution for small projects, prototypes, or for educational purposes where a full-scale database system isn't required.
|
4 | 13 |
|
5 |
| -## Features |
| 14 | +## 🚀 Features |
6 | 15 |
|
7 | 16 | - **Simple CRUD Operations**: Easily create, read, update, and delete records with straightforward Python methods.
|
8 | 17 | - **Lightweight and Portable**: No need for complex database setups. Your data is stored in a single JSON file.
|
9 | 18 | - **Flexible Data Models**: Store anything from simple key-value pairs to complex nested structures.
|
10 | 19 | - **Search Functionality**: Includes basic search capabilities to filter through data based on keys or patterns.
|
11 | 20 | - **Minimal Setup**: With just a few lines of code, integrate JsonDB into any Python project.
|
12 | 21 |
|
13 |
| -## Getting Started |
| 22 | +## 🏁 Getting Started |
14 | 23 |
|
15 | 24 | ### Prerequisites
|
16 | 25 |
|
17 | 26 | - Python 3.6 or newer
|
18 | 27 |
|
19 | 28 | ### Installation
|
20 | 29 |
|
21 |
| -To use the JsonDB in your project, you simply need to include the `jsonDB.py` file in your project directory. There's no need to install any packages or run any setup scripts. Just make sure that `jsonDB.py` is in the same folder as the Python script where you intend to use the database. |
| 30 | +You can download the `jsonDB.py` file directly for your platform using the following commands: |
| 31 | + |
| 32 | +#### Windows |
| 33 | + |
| 34 | +**Option 1: Using PowerShell (no extra installations needed)**: |
| 35 | +Open PowerShell and run: |
| 36 | + |
| 37 | +```powershell |
| 38 | +Invoke-WebRequest -Uri https://raw.githubusercontent.com/DavyJonesCodes/json-db-python/master/jsonDB.py -OutFile jsonDB.py |
| 39 | +``` |
| 40 | + |
| 41 | +**Option 2: Using `wget`**: |
| 42 | +If you have `wget` installed, you can use the following command in Command Prompt or PowerShell: |
| 43 | + |
| 44 | +```cmd |
| 45 | +wget -O jsonDB.py https://raw.githubusercontent.com/DavyJonesCodes/json-db-python/master/jsonDB.py |
| 46 | +``` |
| 47 | + |
| 48 | +#### Linux and macOS |
| 49 | + |
| 50 | +Open your terminal and run: |
| 51 | + |
| 52 | +```bash |
| 53 | +wget -O jsonDB.py https://raw.githubusercontent.com/DavyJonesCodes/json-db-python/master/jsonDB.py |
| 54 | +``` |
22 | 55 |
|
23 | 56 | ### Usage
|
24 | 57 |
|
@@ -47,14 +80,18 @@ del db['user2']
|
47 | 80 | print(db.keys('user.*')) # Output: ['user1']
|
48 | 81 | ```
|
49 | 82 |
|
50 |
| -## Project Structure |
| 83 | +## 📁 Project Structure |
51 | 84 |
|
52 | 85 | - `jsonDb.py`: The core database module, implementing CRUD operations and data storage in JSON format.
|
53 | 86 | - `main.py`: An example script demonstrating how to use the JsonDB for basic data management tasks.
|
54 | 87 | - `data.json`: A sample JSON file used by `main.py` to illustrate data storage and retrieval.
|
55 | 88 |
|
56 |
| -## Contributing |
| 89 | +## 🤝 Contributing |
57 | 90 |
|
58 | 91 | Contributions to the JsonDB Project are welcome! Whether it's reporting a bug, discussing potential improvements, or contributing code, we value your input.
|
59 | 92 |
|
60 | 93 | Please feel free to submit issues and pull requests.
|
| 94 | + |
| 95 | +## 📜 License |
| 96 | + |
| 97 | +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
0 commit comments