File tree Expand file tree Collapse file tree 3 files changed +13
-3
lines changed Expand file tree Collapse file tree 3 files changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -9,4 +9,10 @@ coverage
99# Fortran files
1010* .o
1111* .mod
12- * .smod
12+ * .smod
13+
14+ # Python files
15+ venv /
16+ * .egg-info /
17+ * .eggs /
18+ * .pyc
Original file line number Diff line number Diff line change @@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
99
1010### Added
1111
12+ - Added support for variable resolution in ` fortls `
13+ ([ #664 ] ( https://github.com/fortran-lang/vscode-fortran-support/issues/664 ) )
1214- Added Run and Debug buttons for single Fortran files based on linter settings
1315 ([ #646 ] ( https://github.com/fortran-lang/vscode-fortran-support/issues/646 ) )
1416- Added linter support for [ LFortran] ( https://lfortran.org/ )
Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ import {
1212 isFortran ,
1313 getOuterMostWorkspaceFolder ,
1414 pipInstall ,
15+ resolveVariables ,
1516} from '../lib/tools' ;
1617import { Logger } from '../services/logging' ;
1718import { RestartLS } from '../features/commands' ;
@@ -82,7 +83,8 @@ export class FortlsClient {
8283 if ( ! isFortran ( document ) ) return ;
8384
8485 const args : string [ ] = await this . fortlsArguments ( ) ;
85- const executablePath = workspace . getConfiguration ( EXTENSION_ID ) . get < string > ( 'fortls.path' ) ;
86+ const fortlsPath = workspace . getConfiguration ( EXTENSION_ID ) . get < string > ( 'fortls.path' ) ;
87+ const executablePath = resolveVariables ( fortlsPath ) ;
8688
8789 // Detect language server version and verify selected options
8890 this . version = this . getLSVersion ( executablePath , args ) ;
@@ -304,7 +306,7 @@ export class FortlsClient {
304306 */
305307 private async fortlsDownload ( ) : Promise < boolean > {
306308 const config = workspace . getConfiguration ( EXTENSION_ID ) ;
307- const ls = config . get < string > ( 'fortls.path' ) ;
309+ const ls = resolveVariables ( config . get < string > ( 'fortls.path' ) ) ;
308310
309311 // Check for version, if this fails fortls provided is invalid
310312 const results = spawnSync ( ls , [ '--version' ] ) ;
You can’t perform that action at this time.
0 commit comments