From b394711859ff2000eee057f6d0ae70f4bf37c2c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BE=AE=E5=87=89?= <36558727+Xhofe@users.noreply.github.com> Date: Thu, 31 Dec 2020 17:08:54 +0800 Subject: [PATCH] =?UTF-8?q?:sparkles:=20=E8=87=AA=E5=AE=9A=E4=B9=89?= =?UTF-8?q?=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- conf.yml.example | 1 + conf/config.go | 1 + 2 files changed, 2 insertions(+) diff --git a/conf.yml.example b/conf.yml.example index 3bc567f6..339dfc4c 100644 --- a/conf.yml.example +++ b/conf.yml.example @@ -7,6 +7,7 @@ info: footer_url: https://www.nn.ci #网页底部文字链接 music_img: https://img.oez.cc/2020/12/19/0f8b57866bdb5.gif #预览音乐文件时的图片 check_update: true #前端是否显示更新 + script: #自定义脚本,可以是脚本的链接,也可以直接是脚本内容,如document.querySelector('body').style="background-image:url('https://api.mtyqx.cn/api/random.php');background-attachment:fixed" server: port: "5244" #程序监听端口 search: true #是否开启搜索接口,开启搜索之后密码和根目录都会失效,所以前端暂时不做搜索 diff --git a/conf/config.go b/conf/config.go index a880cff1..515790f7 100644 --- a/conf/config.go +++ b/conf/config.go @@ -10,6 +10,7 @@ type Config struct { FooterUrl string `yaml:"footer_url" json:"footer_url"` MusicImg string `yaml:"music_img" json:"music_img"` CheckUpdate bool `yaml:"check_update" json:"check_update"` + Script string `yaml:"script" json:"script"` } `yaml:"info"` Server struct{ Port string `yaml:"port"`//端口