├── spec ├── fixtures │ ├── empty.py │ ├── pycodestyle │ ├── pycodestyle_backup │ ├── bad.py │ └── good.py ├── .eslintrc.js └── linter-pycodestyle-spec.js ├── .gitattributes ├── .gitignore ├── .editorconfig ├── CONTRIBUTING.md ├── appveyor.yml ├── LICENSE.md ├── README.md ├── package.json ├── .circleci └── config.yml ├── lib └── index.js └── CHANGELOG.md /spec/fixtures/empty.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/pycodestyle: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/pycodestyle_backup: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/bad.py: -------------------------------------------------------------------------------- 1 | import os, path 2 | -------------------------------------------------------------------------------- /spec/fixtures/good.py: -------------------------------------------------------------------------------- 1 | """Simple test file.""" 2 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text eol=lf 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | npm-debug.log 3 | node_modules 4 | .idea 5 | .github_changelog_generator 6 | -------------------------------------------------------------------------------- /spec/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | atomtest: true, 4 | jasmine: true, 5 | }, 6 | rules: { 7 | "import/no-extraneous-dependencies": [ 8 | "error", 9 | { 10 | "devDependencies": true 11 | } 12 | ] 13 | } 14 | }; 15 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig helps developers define and maintain consistent 2 | # coding styles between different editors and IDEs 3 | # editorconfig.org 4 | 5 | root = true 6 | 7 | [*] 8 | 9 | # Change these settings to your own preference 10 | indent_style = space 11 | indent_size = 2 12 | 13 | # We recommend you to keep these unchanged 14 | end_of_line = lf 15 | charset = utf-8 16 | trim_trailing_whitespace = true 17 | insert_final_newline = true 18 | 19 | [*.md] 20 | trim_trailing_whitespace = false 21 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing 2 | 3 | If you would like to contribute enhancements or fixes, please do the following: 4 | 5 | 1. Fork the plugin repository. 6 | 2. Hack on a separate topic branch created from the latest `master`. 7 | 3. Commit and push the topic branch. 8 | 4. Make a pull request. 9 | 5. Welcome to the club! 10 | 11 | Please note that modications should follow these coding guidelines: 12 | 13 | - Indent is 2 spaces. 14 | - Code should pass ESLint linter. 15 | - Vertical whitespace helps readability, don’t be afraid to use it. 16 | 17 | Thank you for helping out! 18 | -------------------------------------------------------------------------------- /appveyor.yml: -------------------------------------------------------------------------------- 1 | ### Project specific config ### 2 | environment: 3 | matrix: 4 | - ATOM_CHANNEL: stable 5 | - ATOM_CHANNEL: beta 6 | 7 | before_build: 8 | - cinst python 9 | - pip install pycodestyle 10 | - pycodestyle --version 11 | 12 | ### Generic setup follows ### 13 | build_script: 14 | - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/atom/ci/master/build-package.ps1')) 15 | 16 | branches: 17 | only: 18 | - master 19 | 20 | version: "{build}" 21 | platform: x64 22 | clone_depth: 10 23 | skip_tags: true 24 | test: off 25 | deploy: off 26 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Jason Emerick 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # linter-pycodestyle 2 | 3 | [![Greenkeeper badge](https://badges.greenkeeper.io/AtomLinter/linter-pycodestyle.svg)](https://greenkeeper.io/) 4 | 5 | This linter plugin for [Linter](https://github.com/AtomLinter/Linter) provides 6 | an interface to [pycodestyle](https://pypi.python.org/pypi/pycodestyle). It will be used 7 | with Python files. 8 | 9 | ## Installation 10 | 11 | Linter package must be installed in order to use this plugin. If Linter is not 12 | installed, please follow the instructions [here](https://github.com/AtomLinter/Linter). 13 | 14 | ### pycodestyle installation 15 | 16 | Before using this plugin, you must ensure that `pycodestyle` is installed on your 17 | system. To install `pycodestyle`, do the following: 18 | 19 | Install [pycodestyle](https://pypi.python.org/pypi/pycodestyle) by typing the following in a 20 | terminal: 21 | 22 | ```ShellSession 23 | pip install pycodestyle 24 | ``` 25 | 26 | Now you can proceed to install the linter-pycodestyle plugin. 27 | 28 | ### Plugin installation 29 | 30 | ```ShellSession 31 | apm install linter-pycodestyle 32 | ``` 33 | 34 | ## Settings 35 | 36 | You can configure linter-pycodestyle from the settings menu: 37 | 38 | * **executablePath** Path to your pycodestyle executable. This is useful if you 39 | have different versions of pycodestyle for Python 2 and 3 or if you are using a 40 | virtualenv 41 | 42 | * **maxLineLength** The max line length for your python code, defaults to 79 43 | 44 | * **ignoreErrorCodes** A list of pycodestyle error codes to ignore. For a list of 45 | code visit 46 | 47 | Example: To ignore `W191` and `E501` you would enter something like this: 48 | 49 | ```coffeescript 50 | W191, E501 51 | ``` 52 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "linter-pycodestyle", 3 | "main": "./lib/index", 4 | "version": "2.1.3", 5 | "description": "Linter plugin for pycodestyle", 6 | "repository": "https://github.com/AtomLinter/linter-pycodestyle", 7 | "license": "MIT", 8 | "configSchema": { 9 | "executablePath": { 10 | "type": "string", 11 | "default": "pycodestyle", 12 | "description": "Semicolon separated list of paths to a binary (e.g. `/usr/local/bin/pycodestyle`). Use `$PROJECT` or `$PROJECT_NAME` substitutions for project specific paths e.g. `$PROJECT/.venv/bin/pycodestyle;/usr/bin/pycodestyle`" 13 | }, 14 | "maxLineLength": { 15 | "type": "integer", 16 | "default": 0 17 | }, 18 | "ignoreErrorCodes": { 19 | "title": "Ignored Error Codes", 20 | "type": "array", 21 | "default": [], 22 | "description": "For a list of code visit http://pycodestyle.readthedocs.org/en/latest/intro.html#error-codes" 23 | }, 24 | "convertAllErrorsToWarnings": { 25 | "type": "boolean", 26 | "default": true 27 | }, 28 | "forcedConfig": { 29 | "type": "string", 30 | "default": "", 31 | "description": "Forces `pycodestyle` to use this configuration at all times. Supports substituion of `$PROJECT` and `$PROJECT_NAME`." 32 | } 33 | }, 34 | "scripts": { 35 | "test": "apm test", 36 | "lint": "eslint ." 37 | }, 38 | "engines": { 39 | "atom": ">=1.7.0 <2.0.0" 40 | }, 41 | "dependencies": { 42 | "atom-linter": "10.0.0", 43 | "atom-package-deps": "5.0.0", 44 | "fs-plus": "3.1.1" 45 | }, 46 | "devDependencies": { 47 | "eslint": "5.13.0", 48 | "eslint-config-airbnb-base": "13.1.0", 49 | "eslint-plugin-import": "2.16.0", 50 | "jasmine-fix": "1.3.1" 51 | }, 52 | "package-deps": [ 53 | "linter:2.0.0" 54 | ], 55 | "providedServices": { 56 | "linter": { 57 | "versions": { 58 | "2.0.0": "provideLinter" 59 | } 60 | } 61 | }, 62 | "keywords": [ 63 | "atom", 64 | "python", 65 | "linter", 66 | "pep8", 67 | "pycodestyle" 68 | ], 69 | "eslintConfig": { 70 | "extends": "airbnb-base", 71 | "rules": { 72 | "global-require": "off", 73 | "import/no-unresolved": [ 74 | "error", 75 | { 76 | "ignore": [ 77 | "atom" 78 | ] 79 | } 80 | ] 81 | }, 82 | "globals": { 83 | "atom": true 84 | }, 85 | "env": { 86 | "node": true, 87 | "browser": true 88 | } 89 | }, 90 | "renovate": { 91 | "extends": [ 92 | "config:base" 93 | ] 94 | } 95 | } 96 | -------------------------------------------------------------------------------- /.circleci/config.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | 3 | defaults: &defaults 4 | working_directory: /tmp/project 5 | docker: 6 | - image: circleci/python:latest 7 | environment: 8 | CIRCLE_BUILD_IMAGE: ubuntu 9 | ATOM_CHANNEL: stable 10 | APM_TEST_PACKAGES: language-livescript 11 | DISPLAY: :99 12 | 13 | jobs: 14 | checkout_code: 15 | <<: *defaults 16 | steps: 17 | - checkout 18 | - run: 19 | name: Download Atom test script 20 | command: curl -s -O https://raw.githubusercontent.com/atom/ci/master/build-package.sh 21 | - run: 22 | name: Make Atom script executable 23 | command: chmod u+x build-package.sh 24 | # Restore node_modules from the last build 25 | - restore_cache: 26 | keys: 27 | # Get latest cache for this package.json 28 | - v2-dependencies-{{ checksum "package.json" }} 29 | # Fallback to the last available cache 30 | - v2-dependencies 31 | # Save project state for next steps 32 | - persist_to_workspace: 33 | root: /tmp 34 | paths: 35 | - project 36 | 37 | stable: 38 | <<: *defaults 39 | steps: 40 | # Restore project state 41 | - attach_workspace: 42 | at: /tmp 43 | - run: 44 | name: Update APT 45 | command: sudo apt-get update 46 | # Install some pre-requisite packages and missing dependencies from the atom package 47 | - run: 48 | name: Atom Prerequisites 49 | command: sudo apt-get --assume-yes --quiet --no-install-suggests --no-install-recommends install sudo xvfb libxss1 libasound2 50 | # Fire up a VFB to run Atom in 51 | - run: 52 | name: Create VFB for Atom to run in 53 | command: /usr/bin/Xvfb $DISPLAY -ac -screen 0 1280x1024x16 54 | background: true 55 | - run: 56 | name: Install pycodestyle 57 | command: sudo pip install pycodestyle 58 | - run: 59 | name: pycodestyle Version 60 | command: pycodestyle --version 61 | - run: 62 | name: Atom test 63 | command: ./build-package.sh 64 | # Cache node_modules 65 | - save_cache: 66 | paths: 67 | - node_modules 68 | key: v2-dependencies-{{ checksum "package.json" }} 69 | 70 | beta: 71 | <<: *defaults 72 | environment: 73 | ATOM_CHANNEL: beta 74 | steps: 75 | # Restore project state 76 | - attach_workspace: 77 | at: /tmp 78 | - run: 79 | name: Update APT 80 | command: sudo apt-get update 81 | # Install some pre-requisite packages and missing dependencies from the atom package 82 | - run: 83 | name: Atom Prerequisites 84 | command: sudo apt-get --assume-yes --quiet --no-install-suggests --no-install-recommends install sudo xvfb libxss1 libasound2 85 | # Fire up a VFB to run Atom in 86 | - run: 87 | name: Create VFB for Atom to run in 88 | command: /usr/bin/Xvfb $DISPLAY -ac -screen 0 1280x1024x16 89 | background: true 90 | - run: 91 | name: Install pycodestyle 92 | command: sudo pip install pycodestyle 93 | - run: 94 | name: pycodestyle Version 95 | command: pycodestyle --version 96 | - run: 97 | name: Atom test 98 | command: ./build-package.sh 99 | 100 | workflows: 101 | version: 2 102 | test_package: 103 | jobs: 104 | - checkout_code 105 | - stable: 106 | requires: 107 | - checkout_code 108 | - beta: 109 | requires: 110 | - checkout_code 111 | -------------------------------------------------------------------------------- /spec/linter-pycodestyle-spec.js: -------------------------------------------------------------------------------- 1 | 'use babel'; 2 | 3 | import { join } from 'path'; 4 | import { 5 | // eslint-disable-next-line no-unused-vars 6 | it, fit, wait, beforeEach, afterEach, 7 | } from 'jasmine-fix'; 8 | 9 | const fixturePath = join(__dirname, 'fixtures'); 10 | const goodPath = join(fixturePath, 'good.py'); 11 | const badPath = join(fixturePath, 'bad.py'); 12 | 13 | describe('The pycodestyle provider for Linter', () => { 14 | const { lint } = require('../lib/').provideLinter(); 15 | 16 | beforeEach(async () => { 17 | // Info about this beforeEach() implementation: 18 | // https://github.com/AtomLinter/Meta/issues/15 19 | const activationPromise = atom.packages.activatePackage('linter-pycodestyle'); 20 | 21 | await atom.packages.activatePackage('language-python'); 22 | 23 | atom.packages.triggerDeferredActivationHooks(); 24 | await activationPromise; 25 | }); 26 | 27 | it('should be in the packages list', () => { 28 | expect(atom.packages.isPackageLoaded('linter-pycodestyle')).toBe(true); 29 | }); 30 | 31 | it('should be an active package', () => { 32 | expect(atom.packages.isPackageActive('linter-pycodestyle')).toBe(true); 33 | }); 34 | 35 | describe('checks bad.py and', () => { 36 | let editor = null; 37 | beforeEach(async () => { 38 | editor = await atom.workspace.open(badPath); 39 | }); 40 | 41 | it('verifies that message', async () => { 42 | const messages = await lint(editor); 43 | expect(messages[0].severity).toBe('warning'); 44 | expect(messages[0].excerpt).toBe('E401 multiple imports on one line'); 45 | expect(messages[0].location.file).toBe(badPath); 46 | expect(messages[0].location.position).toEqual([[0, 9], [0, 15]]); 47 | }); 48 | }); 49 | 50 | it('finds nothing wrong with a valid file', async () => { 51 | const editor = await atom.workspace.open(goodPath); 52 | const messages = await lint(editor); 53 | expect(messages.length).toBe(0); 54 | }); 55 | 56 | describe('executable path', () => { 57 | const helpers = require('atom-linter'); 58 | 59 | let editor = null; 60 | 61 | beforeEach(async () => { 62 | atom.project.addPath(fixturePath); 63 | 64 | spyOn(helpers, 'exec'); 65 | 66 | editor = await atom.workspace.open(badPath); 67 | }); 68 | 69 | it('finds executable relative to project', async () => { 70 | atom.config.set('linter-pycodestyle.executablePath', join('$PROJECT', 'pycodestyle')); 71 | await lint(editor); 72 | expect(helpers.exec.mostRecentCall.args[0]).toBe(join(fixturePath, 'pycodestyle')); 73 | }); 74 | 75 | it('finds executable relative to projects', async () => { 76 | const paths = [ 77 | join('$project', 'null'), 78 | join('$pRoJeCt', 'pycodestyle1'), 79 | join('$PrOjEcT', 'pycodestyle2'), 80 | join('$PROJECT', 'pycodestyle'), 81 | ].join(';'); 82 | atom.config.set('linter-pycodestyle.executablePath', paths); 83 | await lint(editor); 84 | expect(helpers.exec.mostRecentCall.args[0]).toBe(join(fixturePath, 'pycodestyle')); 85 | }); 86 | 87 | it('finds executable using project name', async () => { 88 | atom.config.set('linter-pycodestyle.executablePath', join('$PROJECT_NAME', 'pycodestyle')); 89 | await lint(editor); 90 | expect(helpers.exec.mostRecentCall.args[0]).toBe(join('fixtures', 'pycodestyle')); 91 | }); 92 | 93 | it('finds executable using project names', async () => { 94 | const paths = [ 95 | join('$project_name', 'null'), 96 | join('$pRoJeCt_NaMe', 'flake1'), 97 | join('$PrOjEcT_nAmE', 'flake2'), 98 | join('$PROJECT_NAME', 'pycodestyle'), 99 | ].join(';'); 100 | const correct = [ 101 | join('fixtures', 'null'), 102 | join('fixtures', 'flake1'), 103 | join('fixtures', 'flake2'), 104 | join('fixtures', 'pycodestyle'), 105 | ].join(';'); 106 | atom.config.set('linter-pycodestyle.executablePath', paths); 107 | await lint(editor); 108 | expect(helpers.exec.mostRecentCall.args[0]).toBe(correct); 109 | }); 110 | 111 | it('normalizes executable path', async () => { 112 | atom.config.set( 113 | 'linter-pycodestyle.executablePath', 114 | join(fixturePath, '..', 'fixtures', 'pycodestyle'), 115 | ); 116 | await lint(editor); 117 | expect(helpers.exec.mostRecentCall.args[0]).toBe(join(fixturePath, 'pycodestyle')); 118 | }); 119 | 120 | it('finds backup executable', async () => { 121 | const pycodestyleNotFound = join('$PROJECT', 'pycodestyle_notfound'); 122 | const pycodestyleBackup = join(fixturePath, 'pycodestyle_backup'); 123 | atom.config.set( 124 | 'linter-pycodestyle.executablePath', 125 | `${pycodestyleNotFound};${pycodestyleBackup}`, 126 | ); 127 | await lint(editor); 128 | expect(helpers.exec.mostRecentCall.args[0]).toBe(join(fixturePath, 'pycodestyle_backup')); 129 | }); 130 | }); 131 | }); 132 | -------------------------------------------------------------------------------- /lib/index.js: -------------------------------------------------------------------------------- 1 | 'use babel'; 2 | 3 | // eslint-disable-next-line import/no-extraneous-dependencies, import/extensions 4 | import { CompositeDisposable } from 'atom'; 5 | 6 | // Dependencies 7 | let helpers; 8 | let path; 9 | let fs; 10 | 11 | const applySubstitutions = (givenExecPath, projDir) => { 12 | let execPath = givenExecPath; 13 | const projectName = path.basename(projDir); 14 | execPath = execPath.replace(/\$PROJECT_NAME/ig, projectName); 15 | execPath = execPath.replace(/\$PROJECT/ig, projDir); 16 | const paths = execPath.split(';'); 17 | const foundPath = paths.find(testPath => fs.existsSync(testPath)); 18 | if (foundPath) { 19 | return foundPath; 20 | } 21 | return execPath; 22 | }; 23 | 24 | const loadDeps = () => { 25 | if (!helpers) { 26 | helpers = require('atom-linter'); 27 | } 28 | if (!path) { 29 | path = require('path'); 30 | } 31 | if (!fs) { 32 | fs = require('fs-plus'); 33 | } 34 | }; 35 | 36 | module.exports = { 37 | activate() { 38 | this.idleCallbacks = new Set(); 39 | let depsCallbackID; 40 | const installLinterPycodestyleDeps = () => { 41 | this.idleCallbacks.delete(depsCallbackID); 42 | if (!atom.inSpecMode()) { 43 | require('atom-package-deps').install('linter-pycodestyle'); 44 | } 45 | loadDeps(); 46 | }; 47 | depsCallbackID = window.requestIdleCallback(installLinterPycodestyleDeps); 48 | this.idleCallbacks.add(depsCallbackID); 49 | 50 | this.subscriptions = new CompositeDisposable(); 51 | this.subscriptions.add( 52 | atom.config.observe('linter-pycodestyle.maxLineLength', (value) => { 53 | this.maxLineLength = value; 54 | }), 55 | atom.config.observe('linter-pycodestyle.ignoreErrorCodes', (value) => { 56 | this.ignoreCodes = value; 57 | }), 58 | atom.config.observe('linter-pycodestyle.convertAllErrorsToWarnings', (value) => { 59 | this.convertAllErrorsToWarnings = value; 60 | }), 61 | atom.config.observe('linter-pycodestyle.executablePath', (value) => { 62 | this.executablePath = value; 63 | }), 64 | atom.config.observe('linter-pycodestyle.forcedConfig', (value) => { 65 | this.forcedConfig = value; 66 | }), 67 | ); 68 | }, 69 | 70 | deactivate() { 71 | this.idleCallbacks.forEach(callbackID => window.cancelIdleCallback(callbackID)); 72 | this.idleCallbacks.clear(); 73 | this.subscriptions.dispose(); 74 | }, 75 | 76 | provideLinter() { 77 | return { 78 | name: 'pycodestyle', 79 | grammarScopes: ['source.python', 'source.python.django'], 80 | scope: 'file', 81 | lintsOnChange: true, 82 | lint: async (textEditor) => { 83 | const filePath = textEditor.getPath(); 84 | if (!filePath) { 85 | // Editor has no valid path, linting can't continue 86 | return []; 87 | } 88 | const fileContents = textEditor.getText(); 89 | loadDeps(); 90 | 91 | let projectPath = atom.project.relativizePath(filePath)[0]; 92 | if (projectPath === null) { 93 | // Default project directory to file directory if path cannot be determined 94 | projectPath = path.dirname(filePath); 95 | } 96 | 97 | const parameters = []; 98 | if (this.maxLineLength) { 99 | parameters.push(`--max-line-length=${this.maxLineLength}`); 100 | } 101 | if (this.ignoreCodes.length > 0) { 102 | parameters.push(`--ignore=${this.ignoreCodes.join(',')}`); 103 | } 104 | if (this.forcedConfig) { 105 | const forcedConfigPath = fs.normalize(applySubstitutions(this.forcedConfig, projectPath)); 106 | parameters.push(`--config=${forcedConfigPath}`); 107 | } 108 | parameters.push('-'); 109 | 110 | const execOpts = { 111 | cwd: projectPath, 112 | env: process.env, 113 | stdin: fileContents, 114 | ignoreExitCode: true, 115 | }; 116 | 117 | const execPath = fs.normalize(applySubstitutions(this.executablePath, projectPath)); 118 | 119 | const results = await helpers.exec(execPath, parameters, execOpts); 120 | 121 | if (textEditor.getText() !== fileContents) { 122 | // File has changed since the lint was triggered, tell Linter not to update 123 | return null; 124 | } 125 | 126 | const toReturn = []; 127 | const regex = /stdin:(\d+):(\d+):(.*)/g; 128 | const severity = this.convertAllErrorsToWarnings ? 'warning' : 'error'; 129 | 130 | let match = regex.exec(results); 131 | while (match !== null) { 132 | const line = Number.parseInt(match[1], 10) - 1 || 0; 133 | const col = Number.parseInt(match[2], 10) - 1 || 0; 134 | toReturn.push({ 135 | severity, 136 | excerpt: match[3].trim(), 137 | location: { 138 | file: filePath, 139 | position: helpers.generateRange(textEditor, line, col), 140 | }, 141 | }); 142 | match = regex.exec(results); 143 | } 144 | return toReturn; 145 | }, 146 | }; 147 | }, 148 | }; 149 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log 2 | 3 | ## [v2.1.3](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.1.3) (2017-08-24) 4 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.1.2...v2.1.3) 5 | 6 | **Fixed bugs:** 7 | 8 | - Robustify the check for if ignoreCodes are set or not. [\#132](https://github.com/AtomLinter/linter-pycodestyle/pull/132) ([Rotonen](https://github.com/Rotonen)) 9 | 10 | ## [v2.1.2](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.1.2) (2017-08-22) 11 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.1.1...v2.1.2) 12 | 13 | **Fixed bugs:** 14 | 15 | - Require path before usage [\#135](https://github.com/AtomLinter/linter-pycodestyle/pull/135) ([neok-m4700](https://github.com/neok-m4700)) 16 | 17 | ## [v2.1.1](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.1.1) (2017-08-17) 18 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.1.0...v2.1.1) 19 | 20 | **Implemented enhancements:** 21 | 22 | - Cleanup config and enable beta builds [\#128](https://github.com/AtomLinter/linter-pycodestyle/pull/128) ([Arcanemagus](https://github.com/Arcanemagus)) 23 | 24 | **Fixed bugs:** 25 | 26 | - Ignore editors with no path [\#130](https://github.com/AtomLinter/linter-pycodestyle/pull/130) ([Arcanemagus](https://github.com/Arcanemagus)) 27 | 28 | ## [v2.1.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.1.0) (2017-08-15) 29 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.0.2...v2.1.0) 30 | 31 | **Implemented enhancements:** 32 | 33 | - $PROJECT variable doesn't work [\#87](https://github.com/AtomLinter/linter-pycodestyle/issues/87) 34 | - Add support for custom '--config' path [\#59](https://github.com/AtomLinter/linter-pycodestyle/issues/59) 35 | - Implement specs [\#42](https://github.com/AtomLinter/linter-pycodestyle/issues/42) 36 | - Switch to CircleCI 2.0 [\#127](https://github.com/AtomLinter/linter-pycodestyle/pull/127) ([Arcanemagus](https://github.com/Arcanemagus)) 37 | - Add Greenkeeper badge 🌴 [\#126](https://github.com/AtomLinter/linter-pycodestyle/pull/126) ([greenkeeper[bot]](https://github.com/apps/greenkeeper)) 38 | - Switch to CircleCI 1.0 [\#125](https://github.com/AtomLinter/linter-pycodestyle/pull/125) ([Arcanemagus](https://github.com/Arcanemagus)) 39 | - Add CI configuration [\#124](https://github.com/AtomLinter/linter-pycodestyle/pull/124) ([Arcanemagus](https://github.com/Arcanemagus)) 40 | - Rewrite in JS and update [\#122](https://github.com/AtomLinter/linter-pycodestyle/pull/122) ([Arcanemagus](https://github.com/Arcanemagus)) 41 | - Add specs [\#121](https://github.com/AtomLinter/linter-pycodestyle/pull/121) ([lucasdf](https://github.com/lucasdf)) 42 | 43 | **Fixed bugs:** 44 | 45 | - pep8 config files are not being used [\#69](https://github.com/AtomLinter/linter-pycodestyle/issues/69) 46 | - Rewrite in JS and update [\#122](https://github.com/AtomLinter/linter-pycodestyle/pull/122) ([Arcanemagus](https://github.com/Arcanemagus)) 47 | - Fix typo in package description [\#117](https://github.com/AtomLinter/linter-pycodestyle/pull/117) ([ghisvail](https://github.com/ghisvail)) 48 | 49 | ## [v2.0.2](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.0.2) (2017-03-21) 50 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.0.1...v2.0.2) 51 | 52 | **Fixed bugs:** 53 | 54 | - ReferenceError After updating to 2.0.1 \(PEP8 rename to pycodestyle\) [\#115](https://github.com/AtomLinter/linter-pycodestyle/issues/115) 55 | - Has error under pyenv virtualenv [\#89](https://github.com/AtomLinter/linter-pycodestyle/issues/89) 56 | - Define dirname [\#116](https://github.com/AtomLinter/linter-pycodestyle/pull/116) ([Arcanemagus](https://github.com/Arcanemagus)) 57 | 58 | ## [v2.0.1](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.0.1) (2017-03-18) 59 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v2.0.0...v2.0.1) 60 | 61 | **Fixed bugs:** 62 | 63 | - need to rename package to reflect underlying linter: pep8 --\> pycodestyle [\#55](https://github.com/AtomLinter/linter-pycodestyle/issues/55) 64 | - Fixing issue with pyenv complaining about missing pycodestyle [\#107](https://github.com/AtomLinter/linter-pycodestyle/pull/107) ([srolija](https://github.com/srolija)) 65 | 66 | ## [v2.0.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v2.0.0) (2017-01-25) 67 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.3.3...v2.0.0) 68 | 69 | ## [v1.3.3](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.3.3) (2017-01-25) 70 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.3.2...v1.3.3) 71 | 72 | **Fixed bugs:** 73 | 74 | - pycodestyle [\#97](https://github.com/AtomLinter/linter-pycodestyle/pull/97) ([carterbox](https://github.com/carterbox)) 75 | 76 | ## [v1.3.2](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.3.2) (2016-09-06) 77 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.3.1...v1.3.2) 78 | 79 | **Fixed bugs:** 80 | 81 | - Exited with non-zero code [\#82](https://github.com/AtomLinter/linter-pycodestyle/issues/82) 82 | - Ignored non-zero exit codes from pep8 because they are non-fatal by design [\#86](https://github.com/AtomLinter/linter-pycodestyle/pull/86) ([pnb](https://github.com/pnb)) 83 | 84 | ## [v1.3.1](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.3.1) (2016-09-02) 85 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.3.0...v1.3.1) 86 | 87 | **Implemented enhancements:** 88 | 89 | - Update atom-linter to version 8.0.0 🚀 [\#79](https://github.com/AtomLinter/linter-pycodestyle/pull/79) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 90 | - Update atom-linter to version 6.0.0 🚀 [\#71](https://github.com/AtomLinter/linter-pycodestyle/pull/71) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 91 | 92 | ## [v1.3.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.3.0) (2016-04-26) 93 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.2.1...v1.3.0) 94 | 95 | **Implemented enhancements:** 96 | 97 | - Add support for "source.python.django" grammar [\#64](https://github.com/AtomLinter/linter-pycodestyle/issues/64) 98 | - Add 'source.python.django' grammar [\#65](https://github.com/AtomLinter/linter-pycodestyle/pull/65) ([liljaylj](https://github.com/liljaylj)) 99 | - atom-linter@4.6.1 untested ⚠️ [\#58](https://github.com/AtomLinter/linter-pycodestyle/pull/58) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 100 | - Update atom-package-deps to version 4.0.1 🚀 [\#53](https://github.com/AtomLinter/linter-pycodestyle/pull/53) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 101 | - atom-linter@4.5.0 untested ⚠️ [\#50](https://github.com/AtomLinter/linter-pycodestyle/pull/50) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 102 | - improve startup time [\#48](https://github.com/AtomLinter/linter-pycodestyle/pull/48) ([dirk-thomas](https://github.com/dirk-thomas)) 103 | - atom-package-deps@3.0.8 untested ⚠️ [\#46](https://github.com/AtomLinter/linter-pycodestyle/pull/46) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 104 | - atom-linter@4.4.0 untested ⚠️ [\#45](https://github.com/AtomLinter/linter-pycodestyle/pull/45) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 105 | - atom-linter@4.3.4 untested ⚠️ [\#44](https://github.com/AtomLinter/linter-pycodestyle/pull/44) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 106 | 107 | ## [v1.2.1](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.2.1) (2016-01-11) 108 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.2.0...v1.2.1) 109 | 110 | **Implemented enhancements:** 111 | 112 | - Added keywords to package.json to be searchable on atom.io/packages/ [\#39](https://github.com/AtomLinter/linter-pycodestyle/pull/39) ([viatsko](https://github.com/viatsko)) 113 | 114 | ## [v1.2.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.2.0) (2016-01-09) 115 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.1.0...v1.2.0) 116 | 117 | **Implemented enhancements:** 118 | 119 | - Add linter name [\#32](https://github.com/AtomLinter/linter-pycodestyle/issues/32) 120 | - Install `linter` automatically. [\#24](https://github.com/AtomLinter/linter-pycodestyle/issues/24) 121 | - Force EOL to be LF [\#37](https://github.com/AtomLinter/linter-pycodestyle/pull/37) ([Arcanemagus](https://github.com/Arcanemagus)) 122 | - Added package-deps to package.json [\#36](https://github.com/AtomLinter/linter-pycodestyle/pull/36) ([viatsko](https://github.com/viatsko)) 123 | - Provide linter name so it won't be "Unnamed linter" in editor [\#35](https://github.com/AtomLinter/linter-pycodestyle/pull/35) ([viatsko](https://github.com/viatsko)) 124 | - atom-linter@4.3.1 untested ⚠️ [\#34](https://github.com/AtomLinter/linter-pycodestyle/pull/34) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 125 | - atom-linter@4.3.0 untested ⚠️ [\#33](https://github.com/AtomLinter/linter-pycodestyle/pull/33) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 126 | 127 | ## [v1.1.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.1.0) (2015-12-31) 128 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.0.1...v1.1.0) 129 | 130 | **Implemented enhancements:** 131 | 132 | - Document config examples [\#25](https://github.com/AtomLinter/linter-pycodestyle/issues/25) 133 | - atom-linter@4.2.0 untested ⚠️ [\#31](https://github.com/AtomLinter/linter-pycodestyle/pull/31) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 134 | - Update atom-linter to version 4.1.1 🚀 [\#29](https://github.com/AtomLinter/linter-pycodestyle/pull/29) ([greenkeeperio-bot](https://github.com/greenkeeperio-bot)) 135 | - add option to convert errors to warnings [\#23](https://github.com/AtomLinter/linter-pycodestyle/pull/23) ([eteq](https://github.com/eteq)) 136 | 137 | ## [v1.0.1](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.0.1) (2015-07-19) 138 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v1.0.0...v1.0.1) 139 | 140 | **Implemented enhancements:** 141 | 142 | - Max line length setting wrongly overrides .pep8 configuration setting [\#16](https://github.com/AtomLinter/linter-pycodestyle/issues/16) 143 | 144 | **Fixed bugs:** 145 | 146 | - new issue after updating to version linter-pep8 1.0 and linter 1.2.2 [\#21](https://github.com/AtomLinter/linter-pycodestyle/issues/21) 147 | - Linter showing E501 error despite being ignored in config file [\#18](https://github.com/AtomLinter/linter-pycodestyle/issues/18) 148 | - Lint errors not displayed in atom gui [\#11](https://github.com/AtomLinter/linter-pycodestyle/issues/11) 149 | - pep8 error on filesave on Windows [\#9](https://github.com/AtomLinter/linter-pycodestyle/issues/9) 150 | - Uncaught Error: spawn ENOENT [\#4](https://github.com/AtomLinter/linter-pycodestyle/issues/4) 151 | 152 | ## [v1.0.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v1.0.0) (2015-07-09) 153 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v0.2.0...v1.0.0) 154 | 155 | **Implemented enhancements:** 156 | 157 | - Upgrade to the latest API [\#20](https://github.com/AtomLinter/linter-pycodestyle/pull/20) ([steelbrain](https://github.com/steelbrain)) 158 | 159 | **Fixed bugs:** 160 | 161 | - Upcoming linter changes [\#17](https://github.com/AtomLinter/linter-pycodestyle/issues/17) 162 | 163 | ## [v0.2.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v0.2.0) (2015-05-21) 164 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v0.1.0...v0.2.0) 165 | 166 | **Fixed bugs:** 167 | 168 | - Config.unobserve is deprecated. [\#10](https://github.com/AtomLinter/linter-pycodestyle/issues/10) 169 | - Fix deprecated calls [\#14](https://github.com/AtomLinter/linter-pycodestyle/pull/14) ([jsnjack](https://github.com/jsnjack)) 170 | 171 | ## [v0.1.0](https://github.com/AtomLinter/linter-pycodestyle/tree/v0.1.0) (2014-12-15) 172 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v0.0.5...v0.1.0) 173 | 174 | **Implemented enhancements:** 175 | 176 | - Add support for configuration through Settings menu [\#8](https://github.com/AtomLinter/linter-pycodestyle/pull/8) ([evilhamsterman](https://github.com/evilhamsterman)) 177 | 178 | ## [v0.0.5](https://github.com/AtomLinter/linter-pycodestyle/tree/v0.0.5) (2014-08-20) 179 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/v0.0.4...v0.0.5) 180 | 181 | **Implemented enhancements:** 182 | 183 | - Regex fix [\#7](https://github.com/AtomLinter/linter-pycodestyle/issues/7) 184 | 185 | ## [v0.0.4](https://github.com/AtomLinter/linter-pycodestyle/tree/v0.0.4) (2014-08-13) 186 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/0.0.3...v0.0.4) 187 | 188 | **Implemented enhancements:** 189 | 190 | - Join da club [\#1](https://github.com/AtomLinter/linter-pycodestyle/issues/1) 191 | 192 | ## [0.0.3](https://github.com/AtomLinter/linter-pycodestyle/tree/0.0.3) (2014-07-14) 193 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/0.0.2...0.0.3) 194 | 195 | ## [0.0.2](https://github.com/AtomLinter/linter-pycodestyle/tree/0.0.2) (2014-07-09) 196 | [Full Changelog](https://github.com/AtomLinter/linter-pycodestyle/compare/0.0.1...0.0.2) 197 | 198 | **Implemented enhancements:** 199 | 200 | - Show message code in lint messages [\#6](https://github.com/AtomLinter/linter-pycodestyle/pull/6) ([dmnd](https://github.com/dmnd)) 201 | 202 | **Fixed bugs:** 203 | 204 | - Throws "Uncaught TypeError: Cannot read property 'displayBuffer' of undefined" on lint [\#2](https://github.com/AtomLinter/linter-pycodestyle/issues/2) 205 | - Fix constructor [\#3](https://github.com/AtomLinter/linter-pycodestyle/pull/3) ([msom](https://github.com/msom)) 206 | 207 | ## [0.0.1](https://github.com/AtomLinter/linter-pycodestyle/tree/0.0.1) (2014-05-07) 208 | 209 | 210 | \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)* 211 | --------------------------------------------------------------------------------