Ravenports generated: 20 Apr 2020 20:29
[ravenports.git] / bucket_48 / python-yapf
1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
2
3 NAMEBASE=               python-yapf
4 VERSION=                0.29.0
5 KEYWORDS=               python
6 VARIANTS=               py38 py37 py27
7 SDESC[py37]=            Formatter for Python code (PY37)
8 SDESC[py38]=            Formatter for Python code (PY38)
9 SDESC[py27]=            Formatter for Python code (PY27)
10 HOMEPAGE=               none
11 CONTACT=                Python_Automaton[python@ironwolf.systems]
12
13 DOWNLOAD_GROUPS=        main
14 SITES[main]=            PYPI/y/yapf
15 DISTFILE[1]=            yapf-0.29.0.tar.gz:main
16 DF_INDEX=               1
17 SPKGS[py37]=            single
18 SPKGS[py38]=            single
19 SPKGS[py27]=            single
20
21 OPTIONS_AVAILABLE=      PY38 PY37 PY27
22 OPTIONS_STANDARD=       none
23 VOPTS[py37]=            PY38=OFF PY37=ON PY27=OFF
24 VOPTS[py38]=            PY38=ON PY37=OFF PY27=OFF
25 VOPTS[py27]=            PY38=OFF PY37=OFF PY27=ON
26
27 DISTNAME=               yapf-0.29.0
28
29 GENERATED=              yes
30
31 [PY37].USES_ON=                         python:py37
32
33 [PY38].USES_ON=                         python:py38
34
35 [PY27].USES_ON=                         python:py27
36
37 [FILE:2641:descriptions/desc.single]
38 ====
39 YAPF
40 ====
41
42     :alt: PyPI version
43
44     :alt: Build status
45
46     :alt: Coverage status
47
48 Introduction
49 ============
50
51 Most of the current formatters for Python --- e.g., autopep8, and pep8ify
52 ---
53 are made to remove lint errors from code. This has some obvious
54 limitations.
55 For instance, code that conforms to the PEP 8 guidelines may not be
56 reformatted.  But it doesn't mean that the code looks good.
57
58 YAPF takes a different approach. It's based off of `'clang-format'
59 <https://cl
60 ang.llvm.org/docs/ClangFormat.html>`_, developed by Daniel Jasper. In
61 essence,
62 the algorithm takes the code and reformats it to the best formatting that
63 conforms to the style guide, even if the original code didn't violate the
64 style guide. The idea is also similar to the ['gofmt'] tool for the Go
65 programming language: end all holy wars about
66 formatting - if the whole codebase of a project is simply piped through
67 YAPF
68 whenever modifications are made, the style remains consistent throughout
69 the
70 project and there's no point arguing about style in every code review.
71
72 The ultimate goal is that the code YAPF produces is as good as the code
73 that a
74 programmer would write if they were following the style guide. It takes
75 away
76 some of the drudgery of maintaining your code.
77
78 Try out YAPF with this [online demo].
79
80 .. footer::
81
82     YAPF is not an official Google product (experimental or otherwise), it
83 is
84     just code that happens to be owned by Google.
85
86 .. contents::
87
88 Installation
89 ============
90
91 To install YAPF from PyPI:
92
93 .. code-block:: shell
94
95     $ pip install yapf
96
97 (optional) If you are using Python 2.7 and want to enable multiprocessing:
98
99 .. code-block:: shell
100
101     $ pip install futures
102
103 YAPF is still considered in "alpha" stage, and the released version may
104 change
105 often; therefore, the best way to keep up-to-date with the latest
106 development
107 is to clone this repository.
108
109 Note that if you intend to use YAPF as a command-line tool rather than as a
110 library, installation is not necessary. YAPF supports being run as a
111 directory
112 by the Python interpreter. If you cloned/unzipped YAPF into DIR, it's
113 possible to run:
114
115 .. code-block:: shell
116
117     $ PYTHONPATH=DIR python DIR/yapf [options] ...
118
119 Python versions
120 ===============
121
122 YAPF supports Python 2.7 and 3.6.4+. (Note that some Python 3 features may
123 fail
124 to parse with Python versions before 3.6.4.)
125
126 YAPF requires the code it formats to be valid Python for the version YAPF
127 itself
128 runs under. Therefore, if you format Python 3 code with YAPF, run YAPF
129 itself
130 under Python 3 (and similarly for Python 2).
131
132 Usage
133 =====
134
135 Options::
136
137     usage: yapf [-h] [-v] [-d | -i] [-r | -l START-END] [-e PATTERN]
138
139
140 [FILE:97:distinfo]
141 712e23c468506bf12cadd10169f852572ecc61b266258422d45aaf4ad7ef43de       181836 yapf-0.29.0.tar.gz
142