replace __all__ with @public.add decorator
Project description
Installation
$ [sudo] pip install public
Features
- replace
__all__
with@public.add
decorator
before
__all__ = ["func"]
def func():
after
import public
@public.add
def func():
Examples
>>> import public
>>> @public.add
def func(): pass
>>> @public.add
class Cls: pass
>>> __all__
['Cls','func']
>>> public.add("name")
>>> public.add(*["name1","name2"])
>>> __all__
['Cls','func','name','name1','name2']
Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
public-2020.12.3.tar.gz
(2.1 kB
view details)
File details
Details for the file public-2020.12.3.tar.gz
.
File metadata
- Download URL: public-2020.12.3.tar.gz
- Upload date:
- Size: 2.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2919ef9037e2a2d2563f8431adaa09b6b129d5398d0a687e42f00593484a9aa2 |
|
MD5 | 428f1f477f2ec75c2160ff7d9a017fb5 |
|
BLAKE2b-256 | 260ae1ea97f50e248c83acf80c2ab3b41bce8bb674348a6a3af7b7e40bb6aadd |