Skip to content

Commit 6bcf82b

Browse files
committed
update
1 parent d4484b3 commit 6bcf82b

File tree

4 files changed

+48
-13
lines changed

4 files changed

+48
-13
lines changed

.github/workflows/python-publish.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Upload Python Package
2+
3+
on:
4+
release:
5+
types: [created]
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Set up Python
14+
uses: actions/setup-python@v2
15+
with:
16+
python-version: "3.x"
17+
- name: Install dependencies
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install setuptools wheel twine
21+
- name: Build and publish
22+
env:
23+
TWINE_USERNAME: __token__
24+
TWINE_PASSWORD: ${{ secrets.TWINE_TOKEN }}
25+
run: |
26+
python setup.py sdist bdist_wheel
27+
twine upload dist/*

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: ReallySimpleDB tests
1+
name: tests
22

33
on:
44
push:

README.md

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,26 @@
1-
<h1 align="center">
1+
<center><h1>
22
ReallySimpleDB 🧩
3-
4-
<img src="assets/images/ReallySimpleDB.png" alt="Icon" height="300"> </img>
5-
6-
[![made-with-python](https://img.shields.io/badge/Made%20with-Python-1f425f.svg)](https://www.python.org/) [![Codacy Badge](https://app.codacy.com/project/badge/Grade/09b9e60691484c29b4cac87178b8aaae)](https://www.codacy.com/gh/truethari/ReallySimpleDB/dashboard?utm_source=github.com&utm_medium=referral&utm_content=truethari/ReallySimpleDB&utm_campaign=Badge_Grade)
7-
83
</h1>
94

10-
---
11-
12-
**🔧 This is still in development and may cause errors when using certain functions.**
5+
<img src="assets/images/ReallySimpleDB.png" alt="Icon" height="300"> </img>
136

14-
---
7+
[![PyPI version](https://img.shields.io/pypi/v/ReallySimpleDB.svg?logo=pypi&logoColor=FFE873)](https://pypi.org/project/ReallySimpleDB/) [![tests](https://github.com/truethari/ReallySimpleDB/actions/workflows/tests.yml/badge.svg?branch=alpha)](https://github.com/truethari/ReallySimpleDB/actions/workflows/tests.yml) [![made-with-python](https://img.shields.io/badge/Made%20with-Python-1f425f.svg)](https://www.python.org/) [![Codacy Badge](https://app.codacy.com/project/badge/Grade/09b9e60691484c29b4cac87178b8aaae)](https://www.codacy.com/gh/truethari/ReallySimpleDB/dashboard?utm_source=github.com&utm_medium=referral&utm_content=truethari/ReallySimpleDB&utm_campaign=Badge_Grade) [![PyPI downloads](https://img.shields.io/pypi/dm/reallysimpledb.svg)](https://pypistats.org/packages/reallysimpledb)
158

169
## What is This
1710

1811
---
1912

2013
This is a Python application that can be used to manage **sqlite** databases without using any sql command.
2114

15+
</center>
16+
2217
## 🚀 Installation
2318

2419
You can use pip:
2520

26-
~~pip3 install ReallySimpleDB~~
21+
```console
22+
pip3 install ReallySimpleDB
23+
```
2724

2825
or
2926

@@ -75,13 +72,15 @@ If you want to add columns to an existing table, read the **Add column to table*
7572

7673
```console
7774
>> all_tables = _dbmanager.all_tables()
75+
7876
["STUDENT", "EXAM"]
7977
```
8078

8179
### Check table if exists
8280

8381
```console
8482
>> _dbmanager.is_table(database="test.db", table_name="STUDENTS")
83+
8584
True
8685
```
8786

@@ -101,27 +100,31 @@ True
101100

102101
```console
103102
>> _dbmanager.get_columns(table="STUDENTS")
103+
104104
["student_id", "name", "mark"]
105105
```
106106

107107
### Get all columns with types
108108

109109
```console
110110
>> all_columns = _dbmanager.get_all_column_types(table="STUDENTS")
111+
111112
{"student_id": "TEXT", "name": "TEXT", "mark": "INT"}
112113
```
113114

114115
### Get columns type
115116

116117
```console
117118
>> _dbmanager.get_column_type(table="STUDENTS", column="student_id")
119+
118120
"TEXT"
119121
```
120122

121123
### Get primary key of a table
122124

123125
```console
124126
>> _dbmanager.get_primary_key(table="STUDENTS")
127+
125128
"student_id"
126129
```
127130

@@ -135,13 +138,15 @@ True
135138

136139
```console
137140
>> _dbmanager.get_all_records(table="STUDENTS", primary_key="1010")
141+
138142
[{'student_id': '1010', 'name': 'ABC', 'mark': 10, 'year': '2022'}, {'student_id': '1011', 'name': 'DEF', 'mark': 100, 'year': '2022'}]
139143
```
140144

141145
### Get record from a table
142146

143147
```console
144148
>> _dbmanager.get_record(table="STUDENTS", primary_key="1010")
149+
145150
{'student_id': '1010', 'name': 'ABC', 'mark': 10, 'year': '2022'}
146151
```
147152

@@ -155,9 +160,12 @@ True
155160

156161
```console
157162
>> _dbmanager.filter_records(table="STUDENTS", values={"year":"2022"})
163+
158164
[{'student_id': '1010', 'name': 'ABC', 'mark': 10, 'year': '2022'}, {'student_id': '1011', 'name': 'DEF', 'mark': 100, 'year': '2022'}]
159165
```
160166

167+
---
168+
161169
## 🌱 Contributing Guide
162170

163171
- Fork the project from the `alpha` branch and submit a Pull Request (PR)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
setup(
99
name="ReallySimpleDB",
10-
version="0.0.2",
10+
version="1.0",
1111
description="A tool for easily manage databases with Python",
1212
long_description=long_description,
1313
long_description_content_type="text/markdown",

0 commit comments

Comments
 (0)