File tree 3 files changed +24
-5
lines changed
3 files changed +24
-5
lines changed Original file line number Diff line number Diff line change 1
1
{
2
- // 使用 IntelliSense 了解相关属性。
3
- // 悬停以查看现有属性的描述。
4
- // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
5
2
"version" : " 0.2.0" ,
6
3
"configurations" : [
7
4
{
8
5
"name" : " Python: Nonebot" ,
9
- "type" : " python " ,
6
+ "type" : " debugpy " ,
10
7
"request" : " launch" ,
11
8
"program" : " ${workspaceFolder}/bot.py" ,
12
9
"console" : " integratedTerminal" ,
Original file line number Diff line number Diff line change 1
1
{
2
- "python.formatting.provider" : " autopep8"
2
+ "[python]" : {
3
+ "diffEditor.ignoreTrimWhitespace" : false ,
4
+ "editor.defaultFormatter" : " ms-python.autopep8" ,
5
+ "editor.formatOnType" : true ,
6
+ "editor.formatOnSave" : true
7
+ },
8
+ "python.languageServer" : " Pylance" ,
9
+ "python.analysis.typeCheckingMode" : " basic"
3
10
}
Original file line number Diff line number Diff line change
1
+ import nonebot
2
+ from nonebot .adapters .onebot .v11 import Adapter as ONEBOT_V11Adapter
3
+
4
+
5
+
6
+ nonebot .init ()
7
+
8
+ driver = nonebot .get_driver ()
9
+ driver .register_adapter (ONEBOT_V11Adapter )
10
+
11
+
12
+ nonebot .load_from_toml ("pyproject.toml" )
13
+
14
+ if __name__ == "__main__" :
15
+ nonebot .run ()
You can’t perform that action at this time.
0 commit comments