Skip to content

A Library For Dynamically Importing Modules. Inspired By Node.js `require` Function.

License

Notifications You must be signed in to change notification settings

ShardulNalegave/use.py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Use

A Library For Dynamically Importing Modules. Inspired By Node.js require Function.


Installation

Use can be installed using Pip by the command:-


    [sudo] pip install use

Usage

If the file structure is like:-


    test/
    	test/
    		__init__.py
    		test.py
    		utils/
    			__init__.py
    			utils.py

If you want to import test/test/__init__.py in the file test/test/utils/utils.py it is not possible, but using Use you can do it by putting the following snippet in test/test/utils/utils.py file.


    from use import use

    initFile = use("./../__init__")


License Under The MIT License A Project By Shardul Nalegave

About

A Library For Dynamically Importing Modules. Inspired By Node.js `require` Function.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages