Spring Boot 自定义 Banner,让你的 Banner 更具有个性
🙏废话不多说系列,直接开整🙏
下面是 Spring Boot 自定义的 启动 Bannner。
自定义Banner步骤:
-
在resources目录下,新建文件 banner.txt;
-
使用自动生成Banner图标的网址生成,复制到 banner.txt 文件中即可。
# 自定义spring boot的banner 1. 网址1: http://patorjk.com/software/taag 2. 网址2: http://www.network-science.de/ascii/
-
Spring Boot 的配置文件
application.yml
或者bootstrap.yml
;spring: main: banner-mode: LOG # (CONSOLE/LOG/OFF)关闭 SpringBoot 启动的 banner 标签 banner: location: banner.txt # 自定义 SpringBoot 启动的 banner 标签
-
输出结果:
___________ _________ __ .__ .__ __ ___/__.__.______ ____ / _____/ ____ _____ _____/ |_| |__ |__| ____ ____ | | < | |____ _/ __ \ _____ \ / _ \ / _/ __ \ __\ | | |/ \ / ___\ | | ___ || |_> > ___/ / ( <_> ) Y Y \ ___/| | | Y \ | | / /_/ > |____| / ____|| __/ ___ > /_______ /____/|__|_| /___ >__| |___| /__|___| /___ / / |__| / / / / / //_____/
转载自:https://juejin.cn/post/7362309246555783207