mirror of
https://github.com/Eyre-S/Coeur-Morny-Cono.git
synced 2024-11-23 03:27:39 +08:00
添加启动时的 trusted-readers-of-dinner 数据显示和 version 数据显示
This commit is contained in:
parent
a8eb17c53e
commit
ecd4902dbe
@ -1,6 +1,6 @@
|
|||||||
## Core
|
## Core
|
||||||
|
|
||||||
VERSION = 0.6.4.0
|
VERSION = 0.6.5.0
|
||||||
|
|
||||||
# dependencies
|
# dependencies
|
||||||
|
|
||||||
|
@ -4,6 +4,6 @@ package cc.sukazyo.cono.morny;
|
|||||||
* the final field that will be updated by gradle automatically.
|
* the final field that will be updated by gradle automatically.
|
||||||
*/
|
*/
|
||||||
public class GradleProjectConfigures {
|
public class GradleProjectConfigures {
|
||||||
public static final String VERSION = "0.6.4.0";
|
public static final String VERSION = "0.6.5.0";
|
||||||
public static final long COMPILE_TIMESTAMP = 1652197269644L;
|
public static final long COMPILE_TIMESTAMP = 1652768698515L;
|
||||||
}
|
}
|
||||||
|
@ -94,13 +94,16 @@ public class MornyCoeur {
|
|||||||
this.account = loginResult.account;
|
this.account = loginResult.account;
|
||||||
this.username = loginResult.username;
|
this.username = loginResult.username;
|
||||||
this.trusted = new MornyTrusted(master, trustedChat, trustedRDinner);
|
this.trusted = new MornyTrusted(master, trustedChat, trustedRDinner);
|
||||||
|
StringBuilder trustedReadersDinnerIds = new StringBuilder();
|
||||||
|
trusted.getTrustedReadersOfDinnerSet().forEach(id -> trustedReadersDinnerIds.append("\n ").append(id));
|
||||||
logger.info(String.format("""
|
logger.info(String.format("""
|
||||||
trusted param set:
|
trusted param set:
|
||||||
- master (id)
|
- master (id)
|
||||||
%d
|
%d
|
||||||
- trusted chat (id)
|
- trusted chat (id)
|
||||||
%d""",
|
%d
|
||||||
master, trustedChat
|
- trusted reader-of-dinner (id)%s""",
|
||||||
|
master, trustedChat, trustedReadersDinnerIds
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
catch (Exception e) {
|
catch (Exception e) {
|
||||||
|
@ -21,7 +21,7 @@ public class MornyTrusted {
|
|||||||
*/
|
*/
|
||||||
public final long MASTER;
|
public final long MASTER;
|
||||||
|
|
||||||
public final Set<Long> TRUSTED_READERS_OF_DINNER;
|
private final Set<Long> TRUSTED_READERS_OF_DINNER;
|
||||||
|
|
||||||
public MornyTrusted (long master, long trustedChatId, Set<Long> trustedRDinner) {
|
public MornyTrusted (long master, long trustedChatId, Set<Long> trustedRDinner) {
|
||||||
this.TRUSTED_CHAT_ID = trustedChatId;
|
this.TRUSTED_CHAT_ID = trustedChatId;
|
||||||
@ -51,4 +51,8 @@ public class MornyTrusted {
|
|||||||
return TRUSTED_READERS_OF_DINNER.contains(userId);
|
return TRUSTED_READERS_OF_DINNER.contains(userId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Set<Long> getTrustedReadersOfDinnerSet () {
|
||||||
|
return Set.copyOf(TRUSTED_READERS_OF_DINNER);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -168,6 +168,12 @@ public class ServerMain {
|
|||||||
if (showWelcome) logger.info(MornyHello.MORNY_PREVIEW_IMAGE_ASCII);
|
if (showWelcome) logger.info(MornyHello.MORNY_PREVIEW_IMAGE_ASCII);
|
||||||
if (welcomeEchoMode) return;
|
if (welcomeEchoMode) return;
|
||||||
|
|
||||||
|
logger.info(String.format("""
|
||||||
|
ServerMain.java Loaded >>>
|
||||||
|
- version %s(%s)(%d)""",
|
||||||
|
MornySystem.VERSION, MornySystem.getJarMd5(), GradleProjectConfigures.COMPILE_TIMESTAMP
|
||||||
|
));
|
||||||
|
|
||||||
if (key == null) {
|
if (key == null) {
|
||||||
logger.info("Parameter required has no value:\n --token.");
|
logger.info("Parameter required has no value:\n --token.");
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user