gitlab-pypi
A command-line tool for managing Python packages in GitLab's PyPI registry.
GitLab provides a built-in PyPI package registry, but the web UI for browsing and managing packages is limited. gitlab-pypi gives you a fast, readable CLI for listing packages, inspecting versions, and downloading or uploading wheel files — all via the GitLab REST API.
Features
- List packages — see all packages at a glance, with version counts and latest stable version
- Show versions — view all versions for one or more packages, with pre-release filtering
- Download — fetch
.whlfiles from the registry - Upload — publish one or more
.whlfiles to the registry - Delete — remove a package version from the registry
- Multiple output formats — coloured tables (default),
--plainfor piping into pip, or--jsonfor scripting
Zero external dependencies — uses only the Python 3.12+ standard library.
Installation
pip install gitlab-pypi
Configuration
Create a config file at ~/.config/gitlab-pypi/config.json:
{
"url": "https://gitlab.com",
"project": "my-group/my-project",
"token": "glpat-xxxxxxxxxxxx"
}
Or pass these as CLI flags (--url, --project, --token) on each command.
Usage
# List all packages in the registry
gitlab-pypi list
# Show versions for a package (stable only by default)
gitlab-pypi show my-package
# Show all versions including pre-releases
gitlab-pypi show my-package --all
# Plain output for piping into pip or requirements files
gitlab-pypi show my-package --plain
# Download the latest stable wheel
gitlab-pypi download my-package
# Download a specific version
gitlab-pypi download my-package==1.2.3
# Download all versions of a package
gitlab-pypi download my-package --all
# Upload one or more wheels
gitlab-pypi upload dist/my_package-1.0.0-py3-none-any.whl
gitlab-pypi upload dist/*.whl
# Delete a specific version
gitlab-pypi delete my-package==1.0.0
Development
make dev # Create dev environment
make check # Run ruff + pyright
make format # Auto-fix and format code
make build # Build wheel + docs
make docs # Build HTML documentation
Licence
MIT License — Copyright (c) 2026 Cyber Assessment Labs
Metadata
Release files for gitlab-pypi 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gitlab_pypi-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for gitlab_pypi-1.0.0-py3-none-any.whl |
Release files / gitlab_pypi-1.0.0-py3-none-any.whl
| Download URL | gitlab_pypi-1.0.0-py3-none-any.whl |
|---|---|
| Size | 35.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a36fd44193a9dcd622c7a9a9176e34b43db1461fab3bdb683247110d035f0f0a
|
|
BLAKE2b-256 checksum How to use checksums |
096b0f24bc5b22cfbc173d110e3ee875fdff392a098328a5bc6eb4b6c2729172
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|
Security for gitlab-pypi 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.