Changes for ubuntu 16.04.
This commit is contained in:
parent
f2098da47c
commit
b922f29e07
12 changed files with 58 additions and 73 deletions
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
### Installation
|
||||
|
||||
To run vigil: (Tested in Ubuntu 15.10 in gnome-terminal and stterm)
|
||||
To run vigil: (Tested in Ubuntu 16.04 in gnome-terminal and stterm)
|
||||
|
||||
# git clone https://github.com/ahamilton/vigil
|
||||
# cd vigil
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -1,4 +1,4 @@
|
|||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include <iostream>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;153;153;153m[48;2;32;32;32m[3m<iostream>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;106;184;37m[48;2;32;32;32m[1musing[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;106;184;37m[48;2;32;32;32m[1mnamespace[0m[38;2;208;208;208m[48;2;32;32;32m std;[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
>> 0 <238> 3340
|
||||
>> 3 UNARY_POSITIVE
|
||||
>> 4 <152> 46083
|
||||
>> 4 BUILD_TUPLE_UNPACK 46083
|
||||
7 YIELD_VALUE
|
||||
8 INPLACE_FLOOR_DIVIDE
|
||||
9 <0>
|
||||
|
|
|
|||
|
|
@ -1,12 +1,16 @@
|
|||
Useless declaration of a has-scoped method in mainline (did you mean 'my regex http-verb'?)
|
||||
[31m===[0mSORRY![31m===[0m Error while compiling ./input/perl6.p6
|
||||
Two terms in a row
|
||||
at ./input/perl6.p6:30
|
||||
------> [32m<BOL>[33m⏏[31msay 'here';[0m
|
||||
expecting any of:
|
||||
postfix
|
||||
infix stopper
|
||||
infix or meta-infix
|
||||
statement end
|
||||
statement modifier
|
||||
statement modifier loop
|
||||
[31m===[0mSORRY![31m===[0m
|
||||
Two terms in a row across lines (missing semicolon or comma?)
|
||||
at /home/ahamilton/code/vigil/golden-files/./input/perl6.p6:30
|
||||
------> [32msay 'Hello from Perl 6!'[33m⏏[31m<EOL>[0m
|
||||
expecting any of:
|
||||
infix
|
||||
infix stopper
|
||||
postfix
|
||||
statement end
|
||||
statement modifier
|
||||
statement modifier loop
|
||||
Other potential difficulties:
|
||||
Useless declaration of a has-scoped method in mainline (did you mean 'my regex http-verb'?)
|
||||
at /home/ahamilton/code/vigil/golden-files/./input/perl6.p6:11
|
||||
------> [32mregex [33m⏏[31mhttp-verb {[0m
|
||||
|
||||
|
|
@ -1,12 +1,16 @@
|
|||
Useless declaration of a has-scoped method in mainline (did you mean 'my regex http-verb'?)
|
||||
[31m===[0mSORRY![31m===[0m Error while compiling ./input/perl6.pl
|
||||
Two terms in a row
|
||||
at ./input/perl6.pl:30
|
||||
------> [32m<BOL>[33m⏏[31msay 'here';[0m
|
||||
expecting any of:
|
||||
postfix
|
||||
infix stopper
|
||||
infix or meta-infix
|
||||
statement end
|
||||
statement modifier
|
||||
statement modifier loop
|
||||
[31m===[0mSORRY![31m===[0m
|
||||
Two terms in a row across lines (missing semicolon or comma?)
|
||||
at /home/ahamilton/code/vigil/golden-files/./input/perl6.pl:30
|
||||
------> [32msay 'Hello from Perl 6!'[33m⏏[31m<EOL>[0m
|
||||
expecting any of:
|
||||
infix
|
||||
infix stopper
|
||||
postfix
|
||||
statement end
|
||||
statement modifier
|
||||
statement modifier loop
|
||||
Other potential difficulties:
|
||||
Useless declaration of a has-scoped method in mainline (did you mean 'my regex http-verb'?)
|
||||
at /home/ahamilton/code/vigil/golden-files/./input/perl6.pl:11
|
||||
------> [32mregex [33m⏏[31mhttp-verb {[0m
|
||||
|
||||
|
|
@ -1,11 +1,11 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta name="generator" content=
|
||||
"HTML Tidy for Linux/x86 (vers 25 March 2009), see www.w3.org">
|
||||
<title></title>
|
||||
</head>
|
||||
<body>
|
||||
hello
|
||||
</body>
|
||||
</html>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta name="generator" content=
|
||||
"HTML Tidy for Linux (vers 25 March 2009), see www.w3.org">
|
||||
<title></title>
|
||||
</head>
|
||||
<body>
|
||||
hello
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include <stdio.h>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;153;153;153m[48;2;32;32;32m[3m<stdio.h>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;106;184;37m[48;2;32;32;32m[1mint[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;68;127;207m[48;2;32;32;32mmain[0m[38;2;208;208;208m[48;2;32;32;32m()[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;208;208;208m[48;2;32;32;32m{[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include <iostream>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;205;40;40m[48;2;32;32;32m[1m#include[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;153;153;153m[48;2;32;32;32m[3m<iostream>[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;106;184;37m[48;2;32;32;32m[1musing[0m[38;2;208;208;208m[48;2;32;32;32m [0m[38;2;106;184;37m[48;2;32;32;32m[1mnamespace[0m[38;2;208;208;208m[48;2;32;32;32m std;[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
[0m[38;2;255;255;255m[48;2;32;32;32m [0m[38;2;255;255;255m[48;2;0;0;0m
|
||||
|
|
|
|||
|
|
@ -54,8 +54,8 @@ def _parse_proc_mounts():
|
|||
|
||||
def _find_mounts():
|
||||
all_mounts = set(part[1] for part in _parse_proc_mounts())
|
||||
mount_points = {"/", "/usr", "/bin", "/etc", "/lib", "/dev", "/proc",
|
||||
"/home", "/boot", "/opt", "/run", "/root", "/var", "/tmp"}
|
||||
mount_points = {"/", "/usr", "/bin", "/etc", "/lib", "/dev", "/home",
|
||||
"/boot", "/opt", "/run", "/root", "/var", "/tmp"}
|
||||
return all_mounts.intersection(mount_points)
|
||||
|
||||
|
||||
|
|
|
|||
31
tools.py
31
tools.py
|
|
@ -364,7 +364,9 @@ python_profile.dependencies = {"python", "python3"}
|
|||
|
||||
|
||||
def pep8(path):
|
||||
return _run_command([_python_version(path), "-m", "pep8", path])
|
||||
cmd = (["pep8"] if _python_version(path) == "python"
|
||||
else ["python3", "-m", "pep8"])
|
||||
return _run_command(cmd + [path])
|
||||
pep8.dependencies = {"pep8", "python3-pep8"}
|
||||
|
||||
|
||||
|
|
@ -439,7 +441,7 @@ def _perl_version(path):
|
|||
|
||||
def perl_syntax(path):
|
||||
return _run_command([_perl_version(path), "-c", path])
|
||||
perl_syntax.dependencies = {"perl", "perl6"}
|
||||
perl_syntax.dependencies = {"perl", "rakudo"}
|
||||
|
||||
|
||||
def perldoc(path):
|
||||
|
|
@ -457,25 +459,7 @@ perltidy.dependencies = {"perltidy"}
|
|||
|
||||
def perl6_syntax(path):
|
||||
return _run_command(["perl6", "-c", path])
|
||||
perl6_syntax.dependencies = {"perl6"}
|
||||
|
||||
|
||||
def _jlint_tool(tool_type, path):
|
||||
stdout, *rest = _do_command([tool_type, path])
|
||||
status = (Status.ok
|
||||
if "Verification completed: 0 reported messages." in stdout
|
||||
else Status.problem)
|
||||
return status, fill3.Text(stdout)
|
||||
|
||||
|
||||
def antic(path):
|
||||
return _jlint_tool("antic", path)
|
||||
antic.dependencies = {"jlint"}
|
||||
|
||||
|
||||
def jlint(path):
|
||||
return _jlint_tool("jlint", path)
|
||||
jlint.dependencies = {"jlint"}
|
||||
perl6_syntax.dependencies = {"rakudo"}
|
||||
|
||||
|
||||
def splint(path):
|
||||
|
|
@ -568,7 +552,7 @@ uncrustify.dependencies = {"uncrustify"}
|
|||
|
||||
def php5_syntax(path):
|
||||
return _run_command(["php", "--syntax-check", path])
|
||||
php5_syntax.dependencies = {"php5"}
|
||||
php5_syntax.dependencies = {"php"}
|
||||
|
||||
|
||||
#############################
|
||||
|
|
@ -704,8 +688,7 @@ def _tools_for_extension():
|
|||
"pm6": [perl6_syntax, perldoc],
|
||||
"pod": [perldoc],
|
||||
"pod6": [perldoc],
|
||||
"java": [antic, uncrustify],
|
||||
"class": [jlint],
|
||||
"java": [uncrustify],
|
||||
"c": [splint, uncrustify],
|
||||
"h": [splint, uncrustify],
|
||||
"o": [objdump_headers, objdump_disassemble, readelf],
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ import golden
|
|||
import tools
|
||||
|
||||
|
||||
os.environ["TZ"] = "GMT"
|
||||
VIGIL_ROOT = os.path.dirname(__file__)
|
||||
|
||||
|
||||
|
|
@ -129,13 +130,6 @@ class ToolsTestCase(unittest.TestCase):
|
|||
self._test_tool(tools.perl6_syntax,
|
||||
[("perl6.p6", tools.Status.problem)])
|
||||
|
||||
def test_antic(self):
|
||||
self._test_tool(tools.antic,
|
||||
[("closure-util.java", tools.Status.problem)])
|
||||
|
||||
def test_jlint(self):
|
||||
self._test_tool(tools.jlint, [("javaversion.class", tools.Status.ok)])
|
||||
|
||||
def test_uncrustify(self):
|
||||
self._test_tool(tools.uncrustify,
|
||||
[("closure-util.java", tools.Status.problem),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue