File tree Expand file tree Collapse file tree 4 files changed +12
-6
lines changed
java/com/github/_1c_syntax/bsl/languageserver/configuration Expand file tree Collapse file tree 4 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -100,19 +100,24 @@ public class LanguageServerConfiguration {
100100
101101 @ JsonIgnore
102102 @ Setter (value = AccessLevel .NONE )
103- private File configurationFile = new File ( ".bsl-language-server.json" ) ;
103+ private File configurationFile ;
104104
105- @ Value (("${app.globalConfig.path}" ))
105+ @ Value ("${app.configuration.path}" )
106+ @ JsonIgnore
107+ private String configurationFilePath ;
108+
109+ @ Value (("${app.globalConfiguration.path}" ))
106110 @ JsonIgnore
107111 private String globalConfigPath ;
108112
109113 @ PostConstruct
110114 private void init () {
115+ configurationFile = new File (configurationFilePath );
111116 if (configurationFile .exists ()) {
112117 loadConfigurationFile (configurationFile );
113118 return ;
114119 }
115- var configuration = new File (globalConfigPath , ".bsl-language-server.json" );
120+ var configuration = new File (globalConfigPath );
116121 if (configuration .exists ()) {
117122 loadConfigurationFile (configuration );
118123 }
Original file line number Diff line number Diff line change @@ -4,4 +4,5 @@ spring.main.log-startup-info=false
44logging.level.org.springframework.boot.autoconfigure.logging =INFO
55logging.level.org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler =warn
66spring.application.name =BSL Language Server
7- app.globalConfig.path =${user.home}
7+ app.globalConfiguration.path =${user.home}/.bsl-language-server.json
8+ app.configuration.path =.bsl-language-server.json
Original file line number Diff line number Diff line change @@ -9,4 +9,4 @@ logging.level.org.springframework.test.context.support.AnnotationConfigContextLo
99logging.level.org.springframework.test.context.support.AbstractContextLoader =warn
1010logging.level.org.springframework.boot.test.context.SpringBootTestContextBootstrapper =warn
1111app.measures.enabled =true
12- app.globalConfig .path =.
12+ app.globalConfiguration .path =.
Original file line number Diff line number Diff line change @@ -8,4 +8,4 @@ spring.application.name=BSL Language Server
88logging.level.org.springframework.test.context.support.AnnotationConfigContextLoaderUtils =warn
99logging.level.org.springframework.test.context.support.AbstractContextLoader =warn
1010logging.level.org.springframework.boot.test.context.SpringBootTestContextBootstrapper =warn
11- app.globalConfig .path =.
11+ app.globalConfiguration .path =.
You can’t perform that action at this time.
0 commit comments