Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@
"integrity": "sha256:fedd4c11f7adfb64283b578dddc7da906728daa25fa293351c9d913231acf12f"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ linters:
test_folder: repository_checkov

# DEVSKIM
- linter_name: devskim
- class: DevskimLinter
linter_name: devskim
can_output_sarif: true
descriptor_flavors:
- all
Expand Down
14 changes: 14 additions & 0 deletions megalinter/linters/DevskimLinter.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env python3
"""
Use Devskim as a set of language analyzers and rules that provide security "linting" capabilities
"""


class DevskimLinter(Linter):
def execute_lint_command(self, command):
return_code, return_stdout = super().execute_lint_command(command)
if '-E' in command:
# w/-E exit >0 denotes warnings, <0 errors
min(return_code, 0), return_stdout

return return_code, return_stdout
Loading