An open API service indexing awesome lists of open source software.

https://github.com/grandmoff100/jolly

Import modules and files straight from URLs.
https://github.com/grandmoff100/jolly

Last synced: 7 months ago
JSON representation

Import modules and files straight from URLs.

Awesome Lists containing this project

README

          

# Jolly

Import Python code from modules straight from the internet.

```py
from jolly import register_url

# Register a URL of a directory of Python modules, or from single files.
register_url("https://raw.githubusercontent.com/grandmoff100/jolly/master/examples/zipped")

# Import from that URL
import hello

# -> Inside zipped/hello/__init__.py, importing .hello
# -> Inside zipped/hello/hello.py
# -> Hello, world!
# -> Inside zipped/hello/__init__.py (after importing .hello)

# You can also import from zip or tar files!
register_url("https://raw.githubusercontent.com/grandmoff/jolly/master/examples/out.zip")

import zipped.hello

# -> Inside zipped/__init__.py
# -> Inside zipped/hello/__init__.py, importing .hello
# -> Inside zipped/hello/hello.py
# -> Inside zipped/hello/__init__.py (after importing .hello)
```

## TODO

- [ ] Tests