Convert any Image into ASCII Art for a Custom Spring Boot Banner

If you’d like to override the standard Spring Boot banner with something custom, then you’ve come to the right place. Find any image you want to convert to ASCII art. Then, download the following Git Hub project

Now, you can run a script like the following:

./image2ascii -f ~/Downloads/trinity-neo-morpheus-2.jpg -g 57 -w 100 | tee banner.txt

You’ll see something like the following print out (in color):

Trinity, Neo and Morpheus ASCII Art

Now, you simply can put this file banner.txt into the appropriate folder in a Maven built Java project. If you put it into a common library with Autowiring, it will be available more readily to all of your dependent projects.

  • src/main/resources/banner.txt

Now, you can just build and run and you’ll see this print out without any further configurations (following convention over configuration). If you really want to tweak the configurations you can use some of the following properties in the application.properties 


spring.banner.charset: It configures banner encoding. Default is UTF-8
spring.banner.location: It is banner file location. Default is classpath:banner.txt
spring.banner.image.location: It configures banner image file location. Default is classpath:banner.gif. File can also be jpg, png.
spring.banner.image.width: It configures width of the banner image in char. Default is 76.
spring.banner.image.height: It configures height of the banner image in char. Default is based on image height.
spring.banner.image.margin: It is left hand image margin in char. Default is 2.
spring.banner.image.invert: It configures if images should be inverted for dark terminal themes. Default is false.
spring.main.banner-mode=off

As, you can see you can use images as well. Also, if you were so inclined, you could even use variable substitution in your ASCII art for printing things out, such as the application name and version number.

216 Comments:

  1. Very interesting information!Perfect just what I was looking for!

  2. It’s really a nice and helpful piece of information. I’m glad that you shared this useful info with us. Please keep us up to date like this. Thanks for sharing.

  3. Such a well-researched piece! It’s evident how much effort you’ve put in.

  4. Compelling read with well-presented arguments. I almost felt persuaded. Almost.

  5. Your blog is a go-to resource, like a favorite coffee shop where the barista knows your order. Always comforting.

  6. Your words carry the weight of knowledge, yet they float like feathers, touching minds with gentle precision.

  7. Each post is a window into your thoughts, and I must say, the view is stunning.

  8. You write with such passion and clarity, it’s like listening to a love song for the mind.

  9. Each post is a window into your thoughts, and I must say, the view is stunning.

  10. Your passion for this subject is infectious. Reading your post has inspired me to learn more.

  11. The unique viewpoints in your writing never fail to impress me. Insightful as always!

  12. Reading your work is like catching up with an old friend; comfortable, enlightening, and always welcome.

  13. This post is packed with useful insights. Thanks for sharing your knowledge!

  14. This article was a joy to enjoy reading. Your enthusiasm is contagious!

  15. Your post resonated with me on many levels. Thank you for writing it!

  16. You’ve done a fantastic job of breaking down this topic. Thanks for the clarity!

  17. Your post has been incredibly helpful. Thank you for the guidance!

  18. You’ve articulated your points with such finesse. Truly a pleasure to enjoy reading.

  19. This post is packed with useful insights. Thanks for sharing your knowledge!

  20. Thank you for the hard work you put into this post. It’s much appreciated!

  21. Your blog is a constant source of inspiration and knowledge. Thank you!

  22. I’m so glad I stumbled upon this article. It was exactly what I needed to enjoy reading!

  23. You’ve done a fantastic job of breaking down this topic. Thanks for the clarity!

  24. Thank you for consistently producing such high-quality content.

  25. You’ve opened my eyes to new perspectives. Thank you for the enlightenment!

  26. You have a unique perspective that I find incredibly valuable. Thank you for sharing.

  27. Incredibly informative post! I learned a lot and look forward to more.

  28. Your creativity and intelligence shine through this post. Amazing job!

  29. I appreciate the balance and fairness in your writing. Great job!

  30. This post is packed with useful insights. Thanks for sharing your knowledge!

  31. This post is packed with useful insights. Thanks for sharing your knowledge!

  32. Such a well-researched piece! It’s evident how much effort you’ve put in.

  33. I’m amazed by the depth and b enjoy readingth of your knowledge. Thanks for sharing!

  34. This article is a perfect blend of informative and entertaining. Well done!

  35. I’m so glad I stumbled upon this article. It was exactly what I needed to enjoy reading!

  36. Incredibly informative post! I learned a lot and look forward to more.

  37. This post is packed with useful insights. Thanks for sharing your knowledge!

  38. This post is a testament to your expertise and hard work. Thank you!

  39. This was a thoroughly insightful enjoy reading. Thank you for sharing your expertise!

  40. Your attention to detail is remarkable. I appreciate the thoroughness of your post.

  41. What a refreshing take on this subject. I completely agree with your points!

  42. This piece was beautifully written and incredibly informative. Thank you for sharing!

  43. Incredibly informative post! I learned a lot and look forward to more.

  44. I’m impressed by your ability to convey such nuanced ideas with clarity.

  45. Thank you for the hard work you put into this post. It’s much appreciated!

  46. I appreciate how you’ve explained things so clearly. It really helped me understand the topic better.

  47. The posts are like a secret garden of knowledge. I’m always excited to see what’s blooming.

  48. The way you articulate The thoughts is as refreshing as the first sip of coffee in the morning.

  49. This was a thoroughly insightful enjoy reading. Thank you for sharing your expertise!

  50. This post is packed with useful insights. Thanks for sharing your knowledge!

Leave a Reply

Your email address will not be published. Required fields are marked *