This project has been archived by its maintainers, and is no longer receiving any updates.
mozilla-linux-pkg-manager
mozilla-releng/mozilla-linux-pkg-manager is a Python tool for managing Mozilla product packages hosted in Linux software repositories.
It can be used to clean-up obsolete Firefox Nightly versions.
Requirements
- Python 3.11 or higher
- Poetry (for dependency management)
Installation
- Install Poetry: If not already installed, install Poetry by following the instructions from the official Poetry website.
- Clone the Repository: Clone the
mozilla-linux-pkg-managerrepository using the commandgit clone https://github.com/mozilla-releng/mozilla-linux-pkg-manager.git. - Install Dependencies: Navigate to the repository's root directory and run
poetry installto install the required dependencies.
Running mozilla-linux-pkg-manager
To run mozilla-linux-pkg-manager, use Poetry with the following command:
poetry run mozilla-linux-pkg-manager clean-up --product [PRODUCT] --channel [CHANNEL] --retention-days [DAYS]
Parameters
--product: Specifies the Mozilla product to manage (e.g.nightly,release,beta). Currently, onlyfirefoxis supported.--channel: Specifies the package channel (e.g.nightly,release,beta). Currently, onlynightlyis supported.--retention-days: Sets the retention period in days for packages in the nightly channel. This parameter is only supported on thenightlychannel.
Example
To clean up nightly packages that are older than 7 days:
poetry run mozilla-linux-pkg-manager clean-up --product firefox --channel nightly --retention-days 7
Building and Installing a Python Wheel
The mozilla-linux-pkg-manager package can be packaged into a wheel file for distribution and installation.
Building the Wheel
- Navigate to the Project Directory: Open your terminal and navigate to the directory where your project is located.
- Build the Package: Execute
poetry buildto create the wheel file. This will generate adistfolder in your project directory containing the.whlfile, whose name may vary based on the version and build.
Installing the Wheel File
- Navigate to the
distDirectory: Move to thedistdirectory where the.whlfile is located. - Install the Wheel File: Use
pip install [wheel-file-name]to install the package. Replace[wheel-file-name]with the actual name of the wheel file generated during the build process.
Using the Installed Package
After installation, the package can be used from anywhere on your system, provided you are running the Python interpreter where it was installed. For example:
mozilla-linux-pkg-manager clean-up --product firefox --channel nightly --retention-days 3
Metadata
Release files for mozilla-linux-pkg-manager 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mozilla_linux_pkg_manager-0.1.0.tar.gz | 9.4 kB | Without provenance | Details for mozilla_linux_pkg_manager-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mozilla_linux_pkg_manager-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for mozilla_linux_pkg_manager-0.1.0-py3-none-any.whl |
Total release size: 19.6 kB
Release files / mozilla_linux_pkg_manager-0.1.0.tar.gz
| Download URL | mozilla_linux_pkg_manager-0.1.0.tar.gz |
|---|---|
| Size | 9.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1174be7906aa26a90ddb8f63e297104255c6c2c1ce5a7dab253704e041af2543
|
|
BLAKE2b-256 checksum How to use checksums |
a6a00fb7f71a39758a01439d5e1f87ec6f366f63b8bb2955f69b57d853f4562a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.2
|
Release files / mozilla_linux_pkg_manager-0.1.0-py3-none-any.whl
| Download URL | mozilla_linux_pkg_manager-0.1.0-py3-none-any.whl |
|---|---|
| Size | 10.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e77c7dfe16cf2a1811cbf6b2be568c5ce98e271828ccb990fb541b79c18b8b07
|
|
BLAKE2b-256 checksum How to use checksums |
2f7d8e3f2f88f88b485df77169c5bf2360e2aecda288c7194e0bfb1c8674ad83
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.2
|
Security for mozilla-linux-pkg-manager 0.1.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.