Skip to content

Instantly share code, notes, and snippets.

@reorx
Forked from rochacbruno/sublime-settings.js
Created March 22, 2012 03:26
Show Gist options
  • Save reorx/2155409 to your computer and use it in GitHub Desktop.
Save reorx/2155409 to your computer and use it in GitHub Desktop.
Sublime text pyflakes ignore for web2py identifiers
/*
SublimeLinter default settings
*/
{
/*
Sets the mode in which SublimeLinter runs:
true - Linting occurs in the background as you type (the default).
false - Linting only occurs when you initiate it.
"load-save" - Linting occurs only when a file is loaded and saved.
*/
"sublimelinter": true,
/*
Maps linters to executables for non-built in linters. If the executable
is not in the default system path, or on posix systems in /usr/local/bin
or ~/bin, then you must specify the full path to the executable.
Linter names should be lowercase.
This is the effective default map; your mappings may override these.
"sublimelinter_executable_map":
{
"perl": "perl",
"php": "php",
"ruby": "ruby"
},
*/
"sublimelinter_executable_map":
{
},
/*
Maps syntax names to linters. This allows variations on a syntax
(for example "Python (Django)") to be linted. The key is
the base filename of the .tmLanguage syntax files, and the value
is the linter name (lowercase) the syntax maps to.
*/
"sublimelinter_syntax_map":
{
"Python Django": "python"
},
// An array of linter names to disable. Names should be lowercase.
"sublimelinter_disable":
[
],
/*
The minimum delay in seconds (fractional seconds are okay) before
a linter is run when the "sublimelinter" setting is true. This allows
you to have background linting active, but defer the actual linting
until you are idle. When this value is greater than the built in linting delay,
errors are erased when the file is modified, since the assumption is
you don"t want to see errors while you type.
*/
"sublimelinter_delay": 0,
// If true, lines with errors or warnings will be filled in with the outline color.
"sublimelinter_fill_outlines": false,
// If true, lines with errors or warnings will have a gutter mark.
"sublimelinter_gutter_marks": false,
// If true, the find next/previous error commands will wrap.
"sublimelinter_wrap_find": true,
// jshint: options for linting JavaScript. See http://jshint.com/#docs for more info.
// By deault, eval is allowed.
"jshint_options":
{
"evil": true
},
// A list of pep8 error numbers to ignore. By default "line too long" errors are ignored.
// The list of error codes is in this file: https://github.com/jcrocholl/pep8/blob/master/pep8.py.
// Search for "Ennn:", where nnn is a 3-digit number.
"pep8_ignore":
[
"E501"
],
/*
If you use SublimeLinter for pyflakes checks, you can ignore some of the "undefined name xxx"
errors (comes in handy if you work with post-processors, globals/builtins available only at runtime, etc.).
You can control what names will be ignored with the user setting "pyflakes_ignore".
Example:
"pyflakes_ignore":
[
"some_custom_builtin_o_mine",
"A_GLOBAL_CONSTANT"
],
*/
"pyflakes_ignore":
[
"URL",
"DAL",
"Field",
"Request",
"Response",
"Session",
"Cookie",
"T",
"A",
"B",
"BEAUTIFY",
"BODY",
"BR",
"BUTTON",
"CENTER",
"CAT",
"CODE",
"COL",
"COLGROUP",
"DIV",
"EM",
"EMBED",
"FIELDSET",
"FORM",
"H1",
"H2",
"H3",
"H4",
"H5",
"H6",
"HEAD",
"HR",
"HTML",
"I",
"IFRAME",
"IMG",
"INPUT",
"LABEL",
"LEGEND",
"LI",
"LINK",
"OL",
"UL",
"MARKMIN",
"MENU",
"META",
"OBJECT",
"ON",
"OPTION",
"P",
"PRE",
"SCRIPT",
"OPTGROUP",
"SELECT",
"SPAN",
"STYLE",
"TABLE",
"TAG",
"TD",
"TEXTAREA",
"TH",
"THEAD",
"TBODY",
"TFOOT",
"TITLE",
"TR",
"TT",
"URL",
"XHTML",
"XML",
"xmlescape",
"embed64",
"CLEANUP",
"CRYPT",
"IS_ALPHANUMERIC",
"IS_DATE_IN_RANGE",
"IS_DATE",
"IS_DATETIME_IN_RANGE",
"IS_DATETIME",
"IS_DECIMAL_IN_RANGE",
"IS_EMAIL",
"IS_EMPTY_OR",
"IS_EXPR",
"IS_FLOAT_IN_RANGE",
"IS_IMAGE",
"IS_IN_DB",
"IS_IN_SET",
"IS_INT_IN_RANGE",
"IS_IPV4",
"IS_LENGTH",
"IS_LIST_OF",
"IS_LOWER",
"IS_MATCH",
"IS_EQUAL_TO",
"IS_NOT_EMPTY",
"IS_NOT_IN_DB",
"IS_NULL_OR",
"IS_SLUG",
"IS_STRONG",
"IS_TIME",
"IS_UPLOAD_FILENAME",
"IS_UPPER",
"IS_URL",
"db",
"crud",
"mail",
"request",
"response",
"session",
"service",
"auth",
"prettydate",
"plugins"
],
// Objective-J: if true, non-ascii characters are flagged as an error.
"sublimelinter_objj_check_ascii": false
}
@lepture
Copy link

lepture commented Mar 22, 2012

用 flake8 吧,干嘛用 pyflakes 呀。

@reorx
Copy link
Author

reorx commented Mar 22, 2012

@lepture 这个是sublime text 的 Linter插件的配置,它用的就是pyflake,肯定改不了呀。不过我自己确实用pyflakes多一点,听你的换flake8试试吧。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment