Can I publish a directory using Ivy?

2019-03-06 19:42发布

I have a python lib, and I want to use Ivy to manage my private libraries.

I python lib file structure looks like:

mylib\
    __init__.py
    f1.py
    f2.py
    ...

Now I want to publish mylib as a whole, instead file by file. In Ivy, I know how to publish one file by using the artifact tag. But how can I publish the whole directory?

标签: python ivy
1条回答
放荡不羁爱自由
2楼-- · 2019-03-06 19:52

The problem with a directory is that it's not very easy to version it's contents... The most common solution to this problem is to create a tar or zip package and publish this to your repository.

3rd party builds consuming the directory can either download and unpack it, or alternatively use the packager resolver to access files inside the package.

The packager resolver does add some complexity, but it's a very powerful feature of ivy. The ivy roundup is an example of an ivy repository designed to hold packager files, making it easier to consume artifacts not available via normal repositories.

Finally, the following answers gives packager resolver examples:

查看更多
登录 后发表回答