Archived
更新数据库名称
This commit is contained in:
10 files changed
+180
-130
No files matched your search
@@ -0,0 +1,4 @@
|
||||
import sys
|
||||
|
||||
|
||||
print(sys.argv)
|
||||
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env python3
|
||||
# -- coding:utf-8 --
|
||||
# @Author: markushammered@gmail.com
|
||||
# @Development Tool: PyCharm
|
||||
# @Create Time: 2022/2/16
|
||||
# @File Name: connectdb.py
|
||||
|
||||
|
||||
import sqlite3
|
||||
|
||||
|
||||
def exec(cmd):
|
||||
try:
|
||||
conn = sqlite3.connect('../../db/count.db')
|
||||
cursor = conn.cursor()
|
||||
cursor.execute(cmd)
|
||||
return cursor.fetchall()
|
||||
finally:
|
||||
cursor.close()
|
||||
conn.close()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
while True:
|
||||
cmd = input('>>>')
|
||||
print(exec(cmd))
|
||||
|
||||
@@ -4,7 +4,7 @@ import os
|
||||
import sqlite3
|
||||
|
||||
|
||||
conn = sqlite3.connect('../assets/theme.db')
|
||||
conn = sqlite3.connect('../../db/theme.db')
|
||||
cursor = conn.cursor()
|
||||
|
||||
file_list = os.listdir('../assets/themes/')
|
||||
|
||||
@@ -10,8 +10,7 @@ import random
|
||||
import base64
|
||||
import sqlite3
|
||||
|
||||
|
||||
conn = sqlite3.connect('../assets/theme.db')
|
||||
conn = sqlite3.connect('../../db/style.db')
|
||||
cursor = conn.cursor()
|
||||
|
||||
|
||||
@@ -30,4 +29,6 @@ def get_all_theme():
|
||||
fp.write(img_data)
|
||||
# if i[1] == '':
|
||||
# print(n)
|
||||
get_all_theme()
|
||||
|
||||
|
||||
get_all_theme()
|
||||
Reference in New Issue
Block a user