This repository was archived by the owner on Sep 25, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwing.py
More file actions
102 lines (81 loc) · 2.52 KB
/
wing.py
File metadata and controls
102 lines (81 loc) · 2.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
# -*- coding: UTF-8 -*-
'''
准备区:
引入需要的插件和需要的数据
'''
#引入插件
import sys
import markdown
#引入文件
import config
#准备数据
global out
out = None
theme = config.theme()
server_begin = 0
'''
函数区:
命名以主题前三个字幕为准
'''
class Out():
def out(self=None):
sys.exit(-1)
out = Out
'''
运行区:
以sys组件读取python3 wing.py XXX中XXX部分的东西
无为激活配置生效
z为使用指南
v为版本号
'''
print('''
╭──────────────────────────────────────────────────────────────╮
│ │
│ lingkong-wing │
│ gitee: https://gitee.com/lingkonggzs/lingkong-wing │
│ by ffxw0720 & lingkong │
│ │
╰──────────────────────────────────────────────────────────────╯
''')
if len(sys.argv) == 1:#无的情况
print("激活配置生效")
if theme=="blog_exhibition":
from blog_exhibition import theme
if theme=="blog_succinct":
from blog_succinct import theme
else:
pass
print("完成")
server_begin = 1
out.out()#退出
if server_begin == 0:#判断无的情况是否已经经过,避免不必要的运行错误
model = sys.argv[1]#如果前面的if通过,说明有东西,那么可以开始检测后面的内容
if model == "z":#使用指南
print("使用指南:")
print('''
输入python3 wing.py XXX中XXX部分的东西
无为激活配置生效
z为使用指南
v为版本号
''')
out.out()#退出
if model == "s":#提醒
print("温馨提示:")
print('''
您所做的是旧版操作,
新版启动请执行"python3 wing.py"
''')
out.out()#退出
if model == "v":#版本号
print("版本号:")
print('''
目前程序开发中
所有的开发版本都会在第三位做文章
V2.2.57-211025
''')
out.out()#退出
else:#错误的情况
print("请确认你的激活方式是否错误")
out.out()#退出
else:
pass