on 4ca3282 help sign in
3 files changed+6−21
since splitsnapshots
unifiedsplit
CHANGELOG.md−7 package.json+2−9 src/extension.ts+4−5
CHANGELOG.md−7
@@ -1,12 +1,5 @@
11# Change Log
22
3−### 0.0.12
4−
5−Fixed a bug where executable paths outside of `$PATH` would fail. (@lzszt)
6−
7−### 0.0.11
8−
9−Added the ability to specify the path to the executable.
103
114### 0.0.10
125
package.json+2−9
@@ -3,7 +3,7 @@
33 "displayName": "Ormolu",
44 "publisher": "ilyakooo0",
55 "description": "Haskell code formatter with ormolu",
6− "version": "0.0.12",
6+ "version": "0.0.10",
77 "repository": {
88 "type": "git",
99 "url": "https://github.com/ilyakooo0/vs-code-ormolu"
@@ -128,13 +128,6 @@
128128 ],
129129 "default": null,
130130 "description": "Custom arguments to pass to ormolu."
131− },
132− "ormolu.executablePath": {
133− "type": [
134− "string"
135− ],
136− "default": "ormolu",
137− "description": "The path to the ormolu executable to use."
138131 }
139132 }
140133 }
@@ -160,4 +153,4 @@
160153 "tslint": "^5.12.1",
161154 "vscode-test": "^1.2.0"
162155 }
163−}
156+}
src/extension.ts+4−5
@@ -15,18 +15,17 @@ export function activate(context: vscode.ExtensionContext) {
1515 return [];
1616 };
1717
18− const cfg = vscode.workspace.getConfiguration("ormolu");
19−
2018 try {
21− proc.execSync(cfg.executablePath + ' --help');
19+ proc.execSync('ormolu --help');
2220 } catch (e) {
2321 return showErrorMessage("Ormolu is not installed", e);
2422 }
2523
26− let command = cfg.executablePath;
24+ const cfg = vscode.workspace.getConfiguration("ormolu");
25+
26+ let command = "ormolu";
2727
2828 command += ` --start-line ${range.start.line + 1} --end-line ${range.end.line + (range.end.character == 0 ? 0 : 1)}`
29− command += ` --stdin-input-file ${document.fileName}`
3029
3130 for (let [key, value] of Object.entries(cfg.extensions)) {
3231 if (value) {