source: trunk/dports/python/py-flake8/Portfile

Last change on this file was 149438, checked in by petr@…, 17 months ago

py-flake8*: update to py-flake8 @2.6.0 and and py-flake8-mccabe @0.5.0 respectively, fixes #51659.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.5 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 149438 2016-06-20 17:25:40Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           python 1.0
6PortGroup           select 1.0
7
8set _name           flake8
9set _n              [string index ${_name} 0]
10
11name                py-${_name}
12version             2.6.0
13categories-append   devel
14platforms           darwin
15supported_archs     noarch
16license             MIT
17
18maintainers         petr openmaintainer
19
20description         The modular source code checker: pep8, pyflakes and Co.
21
22long_description    \
23    Flake8 runs all the tools by launching the single flake8 script. It is \
24    is a wrapper around the following tools: PyFlakes, PEP8 and the McCabe \
25    script by Ned Batchelder. It displays the warnings in a per-file, merged \
26    output, features Git and Mercurial hook and is extendable through \
27    flake8.extension entry points.
28
29homepage            http://flake8.readthedocs.org/
30
31distname            ${_name}-${version}
32master_sites        pypi:${_n}/${_name}/
33
34checksums           md5     f00378a3e9b7ab398b05f70befa112cd \
35                    rmd160  e5cb5371acca5053da48299330f96ed7305a70f2 \
36                    sha256  5ae018121a495edeb83097ba1bdd1a8481db24e1f0d54e8a78edb26ba0df82cf
37
38python.versions     27 34 35
39
40if {${name} ne ${subport}} {
41    depends_build-append    port:py${python.version}-setuptools
42
43    depends_lib-append      port:py${python.version}-pyflakes \
44                            port:py${python.version}-codestyle \
45                            port:py${python.version}-flake8-mccabe
46
47    depends_run-append      port:${_name}_select
48
49    select.group    ${_name}
50    select.file     ${filespath}/${_name}-${python.version}
51    notes "
52To make the Python ${python.branch} version of flake8 the one that is run\
53when you execute the commands without a version suffix, e.g. 'flake8', run:
54
55port select --set ${select.group} [file tail ${select.file}]
56"
57
58    # Adding documentation
59    post-destroot {
60        set dest_doc ${destroot}${prefix}/share/doc/${subport}
61        xinstall -${dest_doc}
62        xinstall -m 755 -W ${worksrcpath} \
63            CHANGES.rst \
64            CONTRIBUTORS.txt \
65            LICENSE \
66            README.rst \
67                ${dest_doc}
68    }
69
70    livecheck.type  none
71} else {
72    livecheck.type  regex
73    livecheck.url   https://pypi.python.org/pypi/${_name}/json
74    livecheck.regex "\"${_name}-(\[.\\d\]+)\\${extract.suffix}\""
75}
Note: See TracBrowser for help on using the repository browser.