Brackets-InteractiveLinter icon indicating copy to clipboard operation
Brackets-InteractiveLinter copied to clipboard

it's not clear how to override default options

Open btm1 opened this issue 9 years ago • 17 comments

how do I specify "unused":false at a project level from my .brackets.json file?

btm1 avatar May 20 '15 19:05 btm1

would that be for eslint? then you will need a .eslintrc file with that option in it.

.brackets.json is purely for configuring which linter runs for each language.

MiguelCastillo avatar May 20 '15 20:05 MiguelCastillo

I'm confused about the format. If I add

{
    "interactive-linter.javascript": ["eslint"]
}

to my brackets.json file, just like that, it fails the linting (ironically).

Does it need to be something like:

"interactive-linter": {
    "interactive-linter.javascript": ["eslint"]
}

bobrocke avatar Jun 01 '15 00:06 bobrocke

Your first format is correct

{
    "interactive-linter.javascript": ["eslint"]
}

By failures, do you mean you need to add a .eslintrc to configure eslint, or interactive linter is failing to do its job?

MiguelCastillo avatar Jun 01 '15 00:06 MiguelCastillo

I get this error:

brackets json www br dev brackets

bobrocke avatar Jun 01 '15 00:06 bobrocke

it looks like you have extra curly brackets surrounding the interactive linter settings. Here is what full .brackets.json looks like.

{
    "fonts.fontSize": "12px",
    "spaceUnits": 2,
    "tabSize": 2,
    "useTabChar": false,
    "interactive-linter.delay": 500,
    "interactive-linter.webworker": true,
    "interactive-linter.coffeescript": [
        "coffeelint"
    ],
    "interactive-linter.javascript": [
        "eslint"
    ],
    "insertHintOnTab": true,
    "brackets-wsSanitizer.enabled": true,
    "brackets-wsSanitizer.newline": true,
    "brackets-wsSanitizer.notification": true
}

MiguelCastillo avatar Jun 01 '15 00:06 MiguelCastillo

Oh! I pasted it in from the example thinking it was the addition to brackets.json. Each is a separate object, instead.

bobrocke avatar Jun 01 '15 00:06 bobrocke

yup. is that working for ya?

MiguelCastillo avatar Jun 01 '15 00:06 MiguelCastillo

I think yes.

bobrocke avatar Jun 01 '15 00:06 bobrocke

But on save I'm getting two checks:

brackets json www br dev brackets

bobrocke avatar Jun 01 '15 00:06 bobrocke

very odd! It means you either two copies of interactive linter running, or somehow interactive linter was unable to find the indicator from the native linter Brackets comes with.

Do you get any errors in the brackets debugging console.log?

MiguelCastillo avatar Jun 01 '15 00:06 MiguelCastillo

This the moment I started to edit the JSON file:

devtools html

But none on save when the second check popped up.

bobrocke avatar Jun 01 '15 00:06 bobrocke

Is there a way to disable "normal" linting and leave only interactive linting?

bobrocke avatar Jun 01 '15 02:06 bobrocke

interactive linter disables the native linter... What version of Brackets are you running? What other extensions are you running? It could be possible that you have another extension that is interfering.

MiguelCastillo avatar Jun 01 '15 03:06 MiguelCastillo

Brackets 1.3

{
    "uuid": "34e8ce42-6930-4e01-a181-765d4a33772a",
    "snapshotTime": 1433133115143,
    "os": "mac",
    "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_3) AppleWebKit/537.36 (KHTML, like Gecko) Brackets/1.3.0 Chrome/39.0.2171.36 Safari/537.36",
    "osLanguage": "en",
    "bracketsLanguage": "en",
    "bracketsVersion": "1.3.0-16022",
    "installedExtensions": [
        {
            "name": "tomorrow-night",
            "version": "1.0.2"
        },
        {
            "name": "brackets-css-color-preview",
            "version": "0.0.7"
        },
        {
            "name": "brackets-editorconfig",
            "version": "0.0.4"
        },
        {
            "name": "brackets-paste-and-indent",
            "version": "0.2.0"
        },
        {
            "name": "brackets-scss-lint",
            "version": "0.2.0"
        },
        {
            "name": "com.doersguild.brackets.phplint",
            "version": "1.0.2"
        },
        {
            "name": "dkehrig.show-whitespace",
            "version": "2.0.1"
        },
        {
            "name": "renanveroneze.brackets-open-terminal-here",
            "version": "0.0.2"
        },
        {
            "name": "scriptin.indent-softwraps",
            "version": "0.2.5"
        },
        {
            "name": "stringconvert",
            "version": "0.8.8"
        },
        {
            "name": "twig",
            "version": "1.0.0"
        },
        {
            "name": "brackets-indent-guides",
            "version": "1.3.3"
        },
        {
            "name": "camden.csslint",
            "version": "2.0.20"
        },
        {
            "name": "camden.jshint",
            "version": "2.2.15"
        },
        {
            "name": "vmalone.fileinfo-toclipboard",
            "version": "1.1.0"
        },
        {
            "name": "brackets-yaml-linter",
            "version": "1.0.0"
        },
        {
            "name": "inspect-editor-dom",
            "version": "0.0.3"
        },
        {
            "name": "de.richter.brackets.jsonlint",
            "version": "0.1.3"
        },
        {
            "name": "php-debugger",
            "version": "0.0.3"
        },
        {
            "name": "edc.brackets-snippets",
            "version": "1.8.1"
        },
        {
            "name": "interactive-linter",
            "version": "1.0.3"
        },
        {
            "name": "brackets-display-shortcuts",
            "version": "1.3.4"
        },
        {
            "name": "open.recent.file",
            "version": "0.5.7"
        },
        {
            "name": "adobe.brackets.extract",
            "version": "0.7.2-1724-release"
        }
    ]
}

bobrocke avatar Jun 01 '15 04:06 bobrocke

Does anything there look out of order?

bobrocke avatar Jun 08 '15 00:06 bobrocke

It's still weird:

brackets json www br dev brackets markdown-utilities js www br dev brackets

bobrocke avatar Jun 08 '15 19:06 bobrocke

If I reload, then the extra linter icon goes away. But if I then switch to another open file, I get both icons again, until I reload.

Does that suggest a root cause?

bobrocke avatar Jun 08 '15 20:06 bobrocke