Skip to content

Instantly share code, notes, and snippets.

@alikulov
Forked from krnd/.flake8
Created August 5, 2019 14:13
Show Gist options
  • Select an option

  • Save alikulov/ae366e9cadc4a9347c075516429e5500 to your computer and use it in GitHub Desktop.

Select an option

Save alikulov/ae366e9cadc4a9347c075516429e5500 to your computer and use it in GitHub Desktop.

Revisions

  1. @krnd krnd revised this gist Apr 23, 2019. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion .flake8
    Original file line number Diff line number Diff line change
    @@ -5,7 +5,9 @@
    #
    # This configuration is based on the generic
    # configuration published on GitHub.
    # (gist:krnd/.flake8)
    #
    # AUTHOR krnd
    # VERSION v1.0
    #
    # SEE ALSO
    # http://flake8.pycqa.org/en/latest/user/options.html
  2. @krnd krnd revised this gist Apr 26, 2018. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion .flake8
    Original file line number Diff line number Diff line change
    @@ -5,7 +5,7 @@
    #
    # This configuration is based on the generic
    # configuration published on GitHub.
    # (gist:krnd/.gitignore)
    # (gist:krnd/.flake8)
    #
    # SEE ALSO
    # http://flake8.pycqa.org/en/latest/user/options.html
  3. @krnd krnd revised this gist Apr 26, 2018. 1 changed file with 8 additions and 6 deletions.
    14 changes: 8 additions & 6 deletions .flake8
    Original file line number Diff line number Diff line change
    @@ -1,15 +1,17 @@
    # .flake8
    #
    # DESCRIPTION
    # Configuration file for the python linter flake8.
    # Configuration file for the python linter flake8.
    #
    # DOCUMENTATION
    # http://flake8.pycqa.org/en/latest/user/options.html
    # Error Codes:
    # - Flake8:
    # This configuration is based on the generic
    # configuration published on GitHub.
    # (gist:krnd/.gitignore)
    #
    # SEE ALSO
    # http://flake8.pycqa.org/en/latest/user/options.html
    # http://flake8.pycqa.org/en/latest/user/error-codes.html
    # - pycodestyle:
    # http://pycodestyle.readthedocs.io/en/latest/intro.html#error-codes
    # http://gist.github.com/krnd
    #

    [flake8]
  4. @krnd krnd revised this gist Apr 21, 2018. No changes.
  5. @krnd krnd revised this gist Apr 21, 2018. No changes.
  6. @krnd krnd revised this gist Apr 21, 2018. No changes.
  7. @krnd krnd created this gist Apr 21, 2018.
    120 changes: 120 additions & 0 deletions .flake8
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,120 @@
    # .flake8
    #
    # DESCRIPTION
    # Configuration file for the python linter flake8.
    #
    # DOCUMENTATION
    # http://flake8.pycqa.org/en/latest/user/options.html
    # Error Codes:
    # - Flake8:
    # http://flake8.pycqa.org/en/latest/user/error-codes.html
    # - pycodestyle:
    # http://pycodestyle.readthedocs.io/en/latest/intro.html#error-codes
    #

    [flake8]

    ################### PROGRAM ################################

    # Specify the number of subprocesses that Flake8 will use to run checks in parallel.
    jobs = auto


    ################### OUTPUT #################################

    ########## VERBOSITY ##########

    # Increase the verbosity of Flake8’s output.
    verbose = 0
    # Decrease the verbosity of Flake8’s output.
    quiet = 0


    ########## FORMATTING ##########

    # Select the formatter used to display errors to the user.
    format = default

    # Print the total number of errors.
    count = True
    # Print the source code generating the error/warning in question.
    show-source = True
    # Count the number of occurrences of each error/warning code and print a report.
    statistics = True


    ########## TARGETS ##########

    # Redirect all output to the specified file.
    output-file = .flake8.log
    # Also print output to stdout if output-file has been configured.
    tee = True


    ################### FILE PATTERNS ##########################

    # Provide a comma-separated list of glob patterns to exclude from checks.
    exclude =
    # git folder
    .git,
    # python cache
    __pycache__,
    # Provide a comma-separate list of glob patterns to include for checks.
    filename =
    *.py


    ################### LINTING ################################

    ########## ENVIRONMENT ##########

    # Provide a custom list of builtin functions, objects, names, etc.
    builtins =


    ########## OPTIONS ##########

    # Report all errors, even if it is on the same line as a `# NOQA` comment.
    disable-noqa = False

    # Set the maximum length that any line (with some exceptions) may be.
    max-line-length = 100
    # Set the maximum allowed McCabe complexity value for a block of code.
    max-complexity = 10
    # Toggle whether pycodestyle should enforce matching the indentation of the opening bracket’s line.
    # incluences E131 and E133
    hang-closing = True


    ########## RULES ##########

    # ERROR CODES
    #
    # E/W - PEP8 errors/warnings (pycodestyle)
    # F - linting errors (pyflakes)
    # C - McCabe complexity error (mccabe)
    #
    # W503 - line break before binary operator

    # Specify a list of codes to ignore.
    ignore =
    W503
    # Specify the list of error codes you wish Flake8 to report.
    select =
    E,
    W,
    F,
    C
    # Enable off-by-default extensions.
    enable-extensions =


    ########## DOCSTRING ##########

    # Enable PyFlakes syntax checking of doctests in docstrings.
    doctests = True

    # Specify which files are checked by PyFlakes for doctest syntax.
    include-in-doctest =
    # Specify which files are not to be checked by PyFlakes for doctest syntax.
    exclude-in-doctest =