Merge lp:~jtv/pyjuju/makefile-fixups into lp:pyjuju
Status: | Merged |
---|---|
Approved by: | Kapil Thangavelu |
Approved revision: | 618 |
Merged at revision: | 620 |
Proposed branch: | lp:~jtv/pyjuju/makefile-fixups |
Merge into: | lp:pyjuju |
Diff against target: |
55 lines (+27/-17) 1 file modified
Makefile (+27/-17) |
To merge this branch: | bzr merge lp:~jtv/pyjuju/makefile-fixups |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Kapil Thangavelu (community) | Approve | ||
Ian Booth | Approve | ||
Review via email: mp+149907@code.launchpad.net |
Commit message
Get "make" targets check, review etc. to work, and warn about missing pep8/pyflakes.
Description of the change
Makefile improvements and fixes.
Whenever I tried to run "make check" or "make review" in a juju branch, I would get output like:
bzr: ERROR: Not a branch: "/".
bzr: ERROR: Not a branch: "/".
bzr: ERROR: Not a branch: "/".
bzr: ERROR: Not a branch: "/".
make: *** [check] Error 1
The errors seem to happen (and I'll admit I don't know how or why) because
there are several lines in the Makefile each defining $(modified) as a shell
command involving bzr. I get the same result on a cloud machine as on my development system.
Giving each of those variables a separate name fixed the errors.
There were also other problems: the linters weren't actually being run, there
was no helpful indication of pep8 and/or pyflakes being missing, newly added
files weren't being checked, greps for ".py" suffixes sometimes neglectedto
escape the dot (so it stood for "any character followed by py"). I fixed all of those.
Finally there were some cosmetic nuisances. Spacing of the command lines was
irregular, and some use of Perl-style regexes in grep became unnecessary.
One of the checks in the "review" target was commented out. I don't know why,
so I left that as-is.
Oh, and I documented some targets, since I was figuring out what they were meant to do anyway.