spring maven profile - set properties file based on compilation profile
问题 I would create some compilation profiles like these: profile name: dev profile name: test profile name: production In src/main/resources I have 3 folders: dev/file.properties test/file.properties production/file.properties Each file contains different values for this properties: - my.prop.one - my.prop.two - my.prop.three After that I would set in Spring classes something like these: @Configuration @PropertySource("file:${profile_name}/file.properties") public class MyConfig{ } How can I do?