'How to distribute additional data files for a Python package (pip)?
I'm working on a Python package that I plan to distribute through PyPI. The basic structure of the package is the following:
ExternalDirectory
├── package
│ ├── subpackage
│ │ ├── file.py
│ │ └── __init__.py
│ └── config
│ ├── config.ini
│ ├── other_config_files
│ │ └── config1.ini
│ └── __init__.py
├── requirements.txt
└── setup.py
The configuration files are included in the config folder. The issue is that some more of these files may be available in the future and some others will be updated from time to time. However, every version of the package will be able to work with these configuration files so, in a way, the package version and the "config version" are independent. I'd like the users to be able to just update the config files if they want to do so without having to get a newer version of the main package.
The package will also be available in GitHub. If the package were only going to be available in this format, I could make the config folder a separate project and then use git submodule, users could only update the submodule, but I don't know how this could work through pip.
Is there a standard way of distributing additional files of a package? The expected users of this package will have enough experience to run some commands.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
