How to change Spring boot logo for Nyan Cat?

When I launch the application, I should see something similar to the following:

. ____ _ __ _ _ /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \\/ ___)| |_)| | | | | || (_| | ) ) ) ) ' |____| .__|_| |_|_| |_\__, | / / / / =========|_|==============|___/=/_/_/_/ 

How to change Spring Boot Logo for Nyan Cat as below:

enter image description here

https://spring.io/blog/2015/11/16/spring-boot-1-3-0-released

+42
spring boot
Nov 19 '15 at 6:47
source share
2 answers

The article already contains most of the information on how to do this:

Color banners

Your banner.txt files can now contain ANSI color codes. You can do crazy things like this:

If you look at the Spring docs , you can find more information on how to configure banner.txt .

So, by adding the banner.txt file to the classpath, you can add your own banner. The tile background can be changed using ${AnsiBackground.NAME} , where NAME is the name of the color. A list of colors can be found in the AnsiColor class.

Below nyan cat you can see a little text with :: Meow :: Running Spring Boot 1.3.0.RC1 :: \ΓΆ/ to create such text, you can use placeholder ${spring-boot.version} .

You can also create a banner programmatically with SpringApplication.setBanner() , but as I already installed, all this is in the docs.

The source for the real Nyan cat banner can be found on GitHub , as pointed out by Stephane .

+32
Nov 19 '15 at 8:01
source share
β€” -

Use Spring Boot Banner Generator ; If you want to use any β€œimage” to create a banner for your Spring boot application.

Copy the generated ASCII characters to / src / main / resources / banner.txt

+10
Oct 03 '16 at 13:22
source share



All Articles