[Pkg-debile-commits] [debile-slave] 61/100: add pep8
Sylvestre Ledru
sylvestre at alioth.debian.org
Mon Aug 19 14:53:09 UTC 2013
This is an automated email from the git hooks/post-receive script.
sylvestre pushed a commit to branch master
in repository debile-slave.
commit c820a6a0b60c4c1ff99b48e6e67b8d11af424940
Author: Paul Tagliamonte <tag at pault.ag>
Date: Sun Jun 2 16:41:26 2013 -0400
add pep8
---
ethel/commands/__init__.py | 1 +
ethel/commands/pep8.py | 5 +++++
ethel/runners/pep8.py | 15 +++++++++++++++
3 files changed, 21 insertions(+)
diff --git a/ethel/commands/__init__.py b/ethel/commands/__init__.py
index 5094afe..ee14ede 100644
--- a/ethel/commands/__init__.py
+++ b/ethel/commands/__init__.py
@@ -3,6 +3,7 @@ import importlib
PLUGINS = {
"build": "ethel.commands.build",
+ "pep8": "ethel.commands.pep8",
"lintian": "ethel.commands.lintian",
"lintian4py": "ethel.commands.lintian4py",
diff --git a/ethel/commands/pep8.py b/ethel/commands/pep8.py
new file mode 100644
index 0000000..9611203
--- /dev/null
+++ b/ethel/commands/pep8.py
@@ -0,0 +1,5 @@
+from ethel.runners.pep8 import pep8
+
+
+def run(dsc, package, job, firehose):
+ return pep8(dsc, firehose)
diff --git a/ethel/runners/pep8.py b/ethel/runners/pep8.py
new file mode 100644
index 0000000..dc778a4
--- /dev/null
+++ b/ethel/runners/pep8.py
@@ -0,0 +1,15 @@
+from ethel.wrappers.pep8 import parse_pep8
+from ethel.utils import run_command, cd
+import os
+
+
+def pep8(dsc, analysis):
+ run_command(["dpkg-source", "-x", dsc, "source"])
+ with cd('source'):
+ out, err, ret = run_command(['pep8', '.'])
+ failed = ret != 0
+
+ for issue in parse_pep8(out.splitlines()):
+ analysis.results.append(issue)
+
+ return (analysis, out, failed)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-debile/debile-slave.git
More information about the Pkg-debile-commits
mailing list