Permalink
Browse files

Drop editorconfig setting requirement (now auto)

  • Loading branch information...
1 parent 572042c commit 73102a87b51b11e8c9de64ce41c87646cc963671 @HookyQR committed Oct 24, 2016
Showing with 7 additions and 11 deletions.
  1. +6 −4 README.md
  2. +1 −2 options.js
  3. +0 −5 package.json
View
@@ -15,9 +15,8 @@ VS Code uses js-beautify internally, but it lacks the ability to modify the styl
otherwise...
3. Settings are translated from your VS Code workspace/user setttings.
-4. Any current editor settings (indent spaces/tabs, line ending) are merged in.
-5. If **`"beautify.editorconfig"` is set to `true`**: editorconfig settings are searched for (See http://editorconfig.org/) and are merged in.
-
+4. Any open editor settings (indent spaces/tabs, line ending) for the specific file are merged in.
+5. Editorconfig settings are searched for (See http://editorconfig.org/) and are merged in.
### VS Code | .jsbeautifyrc settings map:
@@ -37,7 +36,7 @@ extra_liners | html.format.extraLiners
space_after_anon_function | javascript.format<br> .insertSpaceAfterFunctionKeywordForAnonymousFunctions
space_in_paren | javascript.format<br> .insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis
-Note that the `html.format` settings will ONLY be used when the document is html.
+Note that the `html.format` settings will ONLY be used when the document is html. `javascript.format` settings are included always.
Also runs http and css beautify from the same package, as determined by the file extension. The schema indicates which beautifier each of the settings pertains to.
@@ -97,6 +96,9 @@ If you wish to exclude the files that are included by default, set `"beautify.on
Embedded version of js-beautify is v1.6.4.
## Changes:
+### 0.5.1: 24 Oct 2015
+* Remove requirement for `beautify.editorconfig` flag
+
### 0.5.0: 22 Oct 2015
* Remove boolean option for `beautify.onSave` in favour of `"editor.formatOnSave"`
View
@@ -119,8 +119,7 @@ module.exports = (doc, type, formattingOptions) => {
let base = vscode.workspace.rootPath;
let opts = optionsFromVSCode(doc, formattingOptions, type);
let configFile;
- if (vscode.workspace.getConfiguration('beautify')
- .editorconfig) set_file_editorconfig_opts(doc.fileName, opts);
+ set_file_editorconfig_opts(doc.fileName, opts); // this does nothing if no ec file was found
if (!doc.isUntitled) base = path.dirname(doc.fileName);
if (base) configFile = findRecursive(base, '.jsbeautifyrc');
if (!configFile) {
View
@@ -52,11 +52,6 @@
"description": "Set path/file matchers to ignore when attempting to beautify on save. Uses glob path matching.",
"default": ["**/*+(.|_|-)min.*"]
},
- "beautify.editorconfig": {
- "type": "boolean",
- "default": false,
- "description": "Use `.editorconfig` settings"
- },
"beautify.language": {
"type": "object",
"description": "Link file types to the beautifier type",

0 comments on commit 73102a8

Please sign in to comment.