mirror of
https://github.com/zhayujie/chatgpt-on-wechat.git
synced 2026-07-20 13:47:15 +08:00
@@ -98,7 +98,7 @@ def load_config():
|
|||||||
config_path = "./config-template.json"
|
config_path = "./config-template.json"
|
||||||
|
|
||||||
config_str = read_file(config_path)
|
config_str = read_file(config_path)
|
||||||
logger.info("[INIT] config str: {}".format(config_str))
|
logger.debug("[INIT] config str: {}".format(config_str))
|
||||||
|
|
||||||
# 将json字符串反序列化为dict类型
|
# 将json字符串反序列化为dict类型
|
||||||
config = Config(json.loads(config_str))
|
config = Config(json.loads(config_str))
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ if [ "$CHARACTER_DESC" != "" ] ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$EXPIRES_IN_SECONDS" != "" ] ; then
|
if [ "$EXPIRES_IN_SECONDS" != "" ] ; then
|
||||||
sed -i "s/\"expires_in_seconds\".*$/\"expires_in_seconds\": $EXPIRES_IN_SECONDS/" $CHATGPT_ON_WECHAT_CONFIG_PATH
|
sed -i "s/\"expires_in_seconds\".*$/\"expires_in_seconds\": $EXPIRES_IN_SECONDS,/" $CHATGPT_ON_WECHAT_CONFIG_PATH
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# go to prefix dir
|
# go to prefix dir
|
||||||
|
|||||||
Reference in New Issue
Block a user