Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cvzi/requirements
Find updates for packages in requirements.txt on pypi
https://github.com/cvzi/requirements
pypi requirements requirements-txt
Last synced: 17 days ago
JSON representation
Find updates for packages in requirements.txt on pypi
- Host: GitHub
- URL: https://github.com/cvzi/requirements
- Owner: cvzi
- License: gpl-3.0
- Created: 2023-03-22T13:33:41.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-03-27T08:46:38.000Z (almost 2 years ago)
- Last Synced: 2024-11-30T04:40:10.652Z (about 1 month ago)
- Topics: pypi, requirements, requirements-txt
- Language: Python
- Homepage: https://pypi.org/project/requirements.py/
- Size: 235 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# requirements.py
Find updates for packages in requirements.txt on pypi![Screenrecord](https://github.com/cvzi/requirements/raw/screenshots/video.png)
## Usage
You can use the file [requirements.py](https://github.com/cvzi/requirements/blob/main/requirements/requirements.py), simply
run `requirements.py` in a folder that contains a `requirements.txt`Or run `requirements.py path/to/first/requirements.txt path/to/second/requirements.txt`
You can also install the module with its dependencies from [pypi.org](https://pypi.org/project/requirements.py/):
```sh
pip install requirements.py
```Once installed the module can be used directly with `python -m requirements` or the command `requirements`.
It also offers some functions to query pypi and requirements.txt programmatically:
```python
import requirementsrequirements.get_versions("lxml")
[, , , , ...]requirements.parse("lxml == 4.0.0")
('lxml', '==', , '4.0.0', 0)requirements.parse_file("requirements.txt")
[('lxml', '==', , '4.9.0', 0), ('defusedxml', '>=', , '0.6.0', 1)]requirements.check_files(["requirements.txt"])
{
'defusedxml': {
'clause': '=',
'current_version': packaging.version.Version('0.6.0'),
'available_versions': [
packaging.version.Version('0.4'),
packaging.version.Version('0.4.1'),
packaging.version.Version('0.5.0'),
packaging.version.Version('0.6.0'),
packaging.version.Version('0.7.0'),
packaging.version.Version('0.7.1')]},
'lxml': {
'clause': '==',
'current_version': packaging.version.Version('4.9.0'),
'available_versions': [
packaging.version.Version('4.7.1'),
packaging.version.Version('4.8.0'),
packaging.version.Version('4.9.0'),
packaging.version.Version('4.9.1'),
packaging.version.Version('4.9.2'),
...
]}}
```