首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >SublimeLinter:警告: jshint已停用,无法定位jshint

SublimeLinter:警告: jshint已停用,无法定位jshint
EN

Stack Overflow用户
提问于 2014-07-30 15:25:29
回答 2查看 4K关注 0票数 4

这完全是随机发生的。我所做的就是重新启动set,接下来我知道我必须重新设置到git.exe的路径,SublimeLinter jshint就坏了。我已经删除并重新安装了SublimeLinter和SublimLinter的各种命令,试图修复它。

我还在全球范围内用npm安装了jshint。

SublimeLinter默认/用户设置:

代码语言:javascript
复制
{
    "default": {
        "debug": false,
        "delay": 0.25,
        "error_color": "D02000",
        "gutter_theme": "Packages/SublimeLinter/gutter-themes/Default/Default.gutter-theme",
        "gutter_theme_excludes": [],
        "lint_mode": "background",
        "mark_style": "outline",
        "no_column_highlights_line": false,
        "paths": {
            "linux": [],
            "osx": [],
            "windows": ["C:\\Users\\x\\AppData\\Roaming\\npm\\node_modules\\jshint\\bin"]
        },
        "python_paths": {
            "linux": [],
            "osx": [],
            "windows": []
        },
        "rc_search_limit": 3,
        "shell_timeout": 10,
        "show_errors_on_save": false,
        "show_marks_in_minimap": true,
        "syntax_map": {
            "python django": "python",
            "html 5": "html",
            "html (django)": "html",
            "html (rails)": "html",
            "php": "html"
        },
        "warning_color": "DDB700",
        "wrap_find": true
    }
}

控制台:

代码语言:javascript
复制
SublimeLinter: jshint linter loaded 
reloading plugin SublimeLinter.commands
reloading plugin SublimeLinter.sublimelinter
plugins loaded
SublimeLinter: debug mode: on 
SublimeLinter: temp directory: c:\users\x\appdata\local\temp\SublimeLinter3 
SublimeLinter: computed PATH from system:
C:\Users\x\AppData\Roaming\npm\node_modules\jshint\bin
C:\Program Files\Common Files\Microsoft Shared\Windows Live
C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live
C:\Windows\system32
C:\Windows
C:\Windows\System32\Wbem
C:\Windows\System32\WindowsPowerShell\v1.0\
C:\Program Files\ThinkPad\Bluetooth Software\
C:\Program Files\ThinkPad\Bluetooth Software\syswow64
C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static
C:\Program Files (x86)\Common Files\Lenovo
C:\Program Files (x86)\Common Files\Roxio Shared\10.0\DLLShared\
C:\Program Files (x86)\Common Files\Roxio Shared\DLLShared\
C:\Program Files (x86)\Lenovo\Access Connections\
C:\Program Files\Common Files\Lenovo
C:\Program Files (x86)\Lenovo\Client Security Solution
C:\Program Files\Lenovo\Client Security Solution
C:\Program Files (x86)\OpenLDAP\kfw\Binary
C:\Program Files (x86)\Windows Live\Shared
C:\Program Files\Microsoft\Web Platform Installer\
C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\
C:\Program Files\Microsoft SQL Server\110\Tools\Binn\
C:\PROGRA~1\IBM\SQLLIB\BIN
C:\PROGRA~1\IBM\SQLLIB\FUNCTION
C:\Program Files\nodejs\
C:\Python27

SublimeLinter: WARNING: jshint deactivated, cannot locate 'jshint' 
SublimeLinter: found existing HTML syntax, version 3 
SublimeLinter: found existing Rails syntax, version 1 
found 3 files for base name Main.sublime-menu
Package Control: Skipping automatic upgrade, last run at 2014-07-30 10:51:51, next run at 2014-07-30 11:51:51 or after
EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2014-07-30 15:46:11

根据SublimeLinter文档,它要求您在路径中包含linter可执行文件。

大多数linter插件要求您安装linter二进制文件或库,并配置您的路径,以便SublimeLinter能够找到它。您必须遵循linter插件的安装说明才能成功地使用它。

您是否尝试过打开终端窗口并查看如果键入jshint --version会发生什么?如果jshint v2.5.0已经出现在您的路径中,您应该将它看作是响应。

票数 4
EN

Stack Overflow用户

发布于 2014-11-21 21:09:00

此外,如果您和我一样,并且由于工作场所的限制而无法修改Windows PATH变量,您可以添加路径到默认的用户设置,就像我在这里做的对SublimeLinter的评论一样。这适用于崇高3构建3065。

代码语言:javascript
复制
{
    "default": {
        "debug": false,
        "delay": 0.25,
        "error_color": "D02000",
        "gutter_theme": "Packages/SublimeLinter/gutter-themes/Default/Default.gutter-theme",
        "gutter_theme_excludes": [],
        "lint_mode": "background",
        "mark_style": "outline",
        "no_column_highlights_line": false,
        "paths": {
            "linux": [],
            "osx": [],
            "windows": ["C:/Users/myUserName/AppData/Roaming/npm"]
        },
        "python_paths": {
            "linux": [],
            "osx": [],
            "windows": []
        },
        "rc_search_limit": 3,
        "shell_timeout": 10,
        "show_errors_on_save": false,
        "show_marks_in_minimap": true,
        "syntax_map": {
            "python django": "python",
            "html 5": "html",
            "html (django)": "html",
            "html (rails)": "html",
            "php": "html"
        },
        "warning_color": "DDB700",
        "wrap_find": true
    }
}
票数 4
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/25040774

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档