-
Notifications
You must be signed in to change notification settings - Fork 581
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug solving sprint #747
Merged
Bug solving sprint #747
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
4f01f11
requirements: Remove setuptools
AbdealiLoKo 5a4c5c2
GitCommitBear: Improve assertion empty queue
AbdealiLoKo 241726c
GitCommitBear: Add ignore_length_regex setting
AbdealiLoKo 4e5a4d8
LocalBearTestHelper: Return results for checking
AbdealiLoKo dc3d2ec
YapfBear: Catch parse errors and give result
AbdealiLoKo ae85d9d
YapfBear: Add prefer line break setting
AbdealiLoKo c24be59
ESLintBear: Update version of eslint
AbdealiLoKo 6f685f4
MarkdownBear: Update version of remark
AbdealiLoKo 138c7aa
CSSLintBear: Update csslint version
AbdealiLoKo 600ba0b
AlexBear: Update alex version
AbdealiLoKo f8c00cd
KeywordBear: Simplify config for case sensitivity
AbdealiLoKo 35140b4
KeywordBear: Conform to style guide
AbdealiLoKo bfd61fb
KeywordBear: Simplify and optimize using regex
AbdealiLoKo fa70e92
AlexBear: Check if wrong alex is installed
AbdealiLoKo 22cdc8a
JSHintBear: Deprecate "use_es6_syntax"
AbdealiLoKo db8a2de
JSHintBear: Deprecate - "globalstrict" -> "strict"
AbdealiLoKo ee34cdc
bears.configfile: Add new bear - PuppetLintBear
AbdealiLoKo c60e9f5
ESLintBear: Handle corner case if eslint fails
AbdealiLoKo 5c72d4e
requirements: Remove redundant comment abot nltk
AbdealiLoKo 8a3d7fd
generate_packageTest: Use correct casing
AbdealiLoKo b3be8f3
natural_language: Add SpellCheckBear
mr-karan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
from coalib.bearlib.abstractions.Linter import linter | ||
from coalib.bears.requirements.GemRequirement import GemRequirement | ||
|
||
|
||
@linter(executable='puppet-lint', | ||
output_format='regex', | ||
output_regex=r'(?P<line>\d+):(?P<column>\d+):' | ||
r'(?P<severity>warning|error):(?P<message>.+)') | ||
class PuppetLintBear: | ||
''' | ||
Check and correct puppet configuration files using ``puppet-lint``. | ||
|
||
See <http://puppet-lint.com/> for details about the tool. | ||
''' | ||
|
||
LANGUAGES = {"Puppet"} | ||
REQUIREMENTS = {GemRequirement('puppet-lint', '2')} | ||
AUTHORS = {'The coala developers'} | ||
AUTHORS_EMAILS = {'coala-devel@googlegroups.com'} | ||
LICENSE = 'AGPL-3.0' | ||
CAN_FIX = {'Syntax'} | ||
|
||
@staticmethod | ||
def create_arguments(filename, file, config_file): | ||
return ('--log-format', "%{line}:%{column}:%{kind}:%{message}", | ||
filename) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
from bears.configfiles.PuppetLintBear import PuppetLintBear | ||
from tests.LocalBearTestHelper import verify_local_bear | ||
|
||
good_file = """ | ||
file { '/some.conf': | ||
ensure => present, | ||
} | ||
""" | ||
|
||
bad_file = """ | ||
# foo | ||
class test::foo { } | ||
""" | ||
|
||
PuppetLintBearTest = verify_local_bear(PuppetLintBear, | ||
valid_files=(good_file,), | ||
invalid_files=(bad_file,)) |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you add an asciinema URL or file an issue about making one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#784