Skip to content

Commit

Permalink
标准化各模块的版本号
Browse files Browse the repository at this point in the history
  • Loading branch information
kosaka-bun committed Sep 20, 2022
1 parent 137c52d commit c436b5f
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 9 deletions.
7 changes: 7 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# 更新日志

### qqrobot-spring-boot-starter 1.0.0
- 起始版本

### qqrobot-framework 1.0.0
- 起始版本
2 changes: 1 addition & 1 deletion qqrobot-framework/build.gradle
Original file line number Diff line number Diff line change
@@ -1 +1 @@
setupVersion '1.0'
setupVersion '1.0.0'
4 changes: 2 additions & 2 deletions qqrobot-spring-boot-starter/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ plugins {
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
}

setupVersion '1.0'
setupVersion '1.0.0'

ext {
miraiVersion = '2.8.2'
}

dependencyManagement {
imports {
mavenBom 'org.springframework.boot:spring-boot-dependencies:2.5.10'
mavenBom 'org.springframework.boot:spring-boot-dependencies:2.3.5.RELEASE'
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
/**
* 命令方法参数类型,被@Command注解的类必须采用此参数类型
*/
@SuppressWarnings("unused")
@Getter
public class CommandMethodArgs {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,18 +79,24 @@ public void addListener(ListenerHost listener) {
public void init() {
Long qq = basicProperties.getQq();
String password = basicProperties.getPassword();
if(ObjectUtils.anyNull(qq, password)) {
if(!ObjectUtils.allNotNull(qq, password)) {
throw new RuntimeException("QQ号或密码不能为空");
}
boolean redirectLogs = miraiProperties.getRedirectLogs();
//修改配置
BotConfiguration conf = BotConfiguration.getDefault();
//转移日志存放目录,设置设备信息
//定义设备信息文件路径,与存放日志的目录路径
String deviceInfoPath = FileSystems.getDefault().getPath(FileUtils.getClasspath(),
miraiProperties.getWorkDirectory(), "deviceInfo.json").toString();
String logBase = FileSystems.getDefault().getPath(FileUtils.getClasspath(),
miraiProperties.getWorkDirectory(), "log") + File.separator;
String deviceInfoPath = FileSystems.getDefault().getPath(
FileUtils.getClasspath(),
miraiProperties.getWorkDirectory(),
"deviceInfo.json"
).toString();
String logBase = FileSystems.getDefault().getPath(
FileUtils.getClasspath(),
miraiProperties.getWorkDirectory(),
"log"
) + File.separator;
File botLogDir = new File(logBase + "bot");
File networkLogDir = new File(logBase + "network");
//检查文件与目录是否存在,不存在则创建
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ private TesterMessage onLogin(TesterMessage message) {
"不能使用Robot作为用户名");
return res;
}
if(ObjectUtils.anyNull(qq, username) || username.isEmpty()) {
if(!ObjectUtils.allNotNull(qq, username) || username.isEmpty()) {
resData.addProperty("status", false);
resData.addProperty("message", "账号和用户名不能为空");
return res;
Expand Down

0 comments on commit c436b5f

Please sign in to comment.