Oven logo

Oven

public2020.12.3

Published

replace __all__ with @public.add decorator

pip install public

Package Downloads

Weekly DownloadsMonthly Downloads

Authors

Project URLs

Requires Python

Dependencies

    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

    readme42.com