Skip to content
This repository was archived by the owner on Dec 17, 2019. It is now read-only.

Commit db2ab77

Browse files
ccapndaveKrzysztof-Cieslak
authored andcommitted
The linter should also respect the module in "Make special path" (#304)
1 parent 7f767d2 commit db2ab77

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/elmLinter.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ function parseErrorsElm019(line) {
6565
typeof message === 'string'
6666
? message
6767
: '#' + message.string + '#',
68-
)
68+
)
6969
.join(''),
7070
region: problem.region,
7171
type: 'error',
@@ -82,7 +82,7 @@ function parseErrorsElm019(line) {
8282
details: errorObject.message
8383
.map(
8484
message => (typeof message === 'string' ? message : message.string),
85-
)
85+
)
8686
.join(''),
8787
region: {
8888
start: {
@@ -125,9 +125,13 @@ function checkForErrors(filename): Promise<IElmIssue[]> {
125125
filename,
126126
vscode.workspace.rootPath,
127127
);
128+
const specialFile: string = <string>config.get('makeSpecialFile');
128129
const isTestFile = elmTest.fileIsTestFile(filename);
129130
let make;
130131

132+
if (specialFile.length > 0) {
133+
filename = path.resolve(cwd, specialFile);
134+
}
131135
if (utils.isWindows) {
132136
filename = '"' + filename + '"';
133137
}

0 commit comments

Comments
 (0)