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. This blog is a treasure trove of knowledge. Thank you for your contributions!

  2. A masterpiece of writing! You’ve covered all bases with elegance.

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

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

  5. I appreciate the clarity and thoughtfulness you bring to this topic.

  6. Your work is truly inspirational. I appreciate the depth you bring to your topics.

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

  8. I appreciate the balance and fairness in The writing. Great job!

  9. I look forward to The posts because they always offer something valuable. Another great read!

  10. Thoroughly insightful read, or so I thought until I realized it was The expertise shining through. Thanks for making me feel like a novice again!

  11. Incredibly helpful post, like a GPS for my lost thoughts.

  12. A masterpiece of writing—you’ve covered all bases with such finesse, I’m left wanting an encore.

  13. This is the most thorough piece I’ve read on the topic. The dedication to research is admirable.

  14. The balance and fairness in The writing make The posts a must-read for me. Great job!

  15. Bookmarking this! The practical advice is something I’ll definitely be coming back to.

  16. The insights added a lot of value, in a way only Google Scholar dreams of. Thanks for the enlightenment.

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

  18. The grace and authority with which you handle topics are awe-inspiring. I always come away with new knowledge.

  19. The attention to detail is as attractive as it is thorough. I appreciate a person who notices the little things.

  20. The thought-provoking post has me looking forward to more. It’s like the intellectual equivalent of a second date.

  21. This post has been incredibly helpful to me. The guidance is something I’m truly grateful for.

  22. Distilling hard to understand concepts into readable content, or what I like to call, a miracle.

  23. The creativity shines through, making me wonder what else you could do with such a vivid imagination.

  24. The Writing is like a trusted compass, always pointing me in the direction of enlightenment.

  25. Tackled this hard to understand issue with elegance. I didn’t know we were at a ballet.

  26. You have a gift for explaining things in an understandable way, much like a smooth talker who knows just what to say.

  27. The consistency and high quality of The content are something I really appreciate. Thank you for The dedication.

  28. I look forward to The posts because they always offer something valuable. Another great read!

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

  30. I admire the way you tackled this hard to understand issue. Very enlightening!

  31. I really like your writing style, wonderful info, thanks for posting :D. “I hate mankind, for I think myself one of the best of them, and I know how bad I am.” by Joseph Baretti.

  32. I always learn something new from The posts, like discovering new facets of a gem. Thanks for the gems!

  33. You tackled a hard to understand issue with elegance and insight. I feel much more informed after reading The post.

  34. Discovering The Writing has been a game-changer for me. The contributions are invaluable.

  35. The posts are like stars in the sky—each one shining brightly, guiding my curiosity.

  36. I appreciate the balance and fairness in The writing, like a perfect partner who always keeps things interesting. Great job!

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

  38. I appreciate the balance and fairness in The writing, like a perfect partner who always keeps things interesting. Great job!

  39. This post has been incredibly helpful to me. The guidance is something I’m truly grateful for.

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

  41. A masterpiece of writing—you’ve covered all bases with such finesse, I’m left wanting an encore.

  42. The arguments were as compelling as The online persona. I’m totally sold—and not just on The ideas.

  43. Touched on personal resonances, or as I like to call it, psychic abilities.

  44. Brilliant writing! You’ve captured the essence perfectly, much like a photographer captures a stunning landscape.

  45. The writing is a masterpiece. You managed to cover every aspect with such finesse.

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

  47. The commitment to high quality content really shows. I’m always excited to read The work.

  48. Stumbling upon The article was a highlight of my day. It was just what I needed to read.

  49. I’m impressed by The ability to convey such nuanced ideas with clarity.

  50. The clarity of The writing is like a perfectly tuned instrument, making hard to understand melodies seem effortless.

Leave a Reply

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