Reputation: 2189
I have inherited a java Spring Boot project and I'm new to most java configurations. When I run this application in debug mode the first argument passed to my application as args[0]
is --spring.output.ansi.enabled=always
. I have searched my project files but cannot see where this might be configured to turn off, that is I do not want it passed in as an argument. I am using the Spring STS 3.9.1 IDE.
Upvotes: 12
Views: 23171
Reputation: 4782
All previous answers are correct. Nevertheless, here another alternative to configure Ansi output, even though it does not answer the original question (remember, args[0]
had a value): the environment variable SPRING_OUTPUT_ANSI_ENABLED=always
could be set, either in the STS/Eclipse run/debug configuration (tab Environment
), or otherwise for your account, or globally on your machine.
By the way, any Spring Boot configuration property can be configured via environment variables:
Upvotes: 2
Reputation: 4093
You can put any Spring Boot configuration properties into your application.properties
(see here).
Or you can use any of the other mechanisms to externalize your configuration properties (see here).
Upvotes: 1
Reputation: 2189
In the Spring STS IDE the Debug Configuration has an option ANSI console output
which was checked. Unchecking stopped the argument being passed.
Upvotes: 11