# Install twine with Homebrew, apk, apt, dnf, MacPorts, Nix, pacman, scoop, winget

Utilities for interacting with PyPI. Version 6.2.0 via Homebrew; verified 2026-05-15.

## Install

```sh
sudo av install brew:twine
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install twine
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install twine
```

  Evidence: MacPorts ports tree: python/twine/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add twine
```

  Evidence: Alpine Linux edge package indexes: twine from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install twine
```

  Evidence: Debian stable package indexes: twine from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install twine
```

  Evidence: Fedora Rawhide package metadata: twine from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#twine
```

  Evidence: nixpkgs package indexes: twine from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix

- pacman (92%):

```sh
sudo pacman -S twine
```

  Evidence: Arch Linux sync databases: twine from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

### Windows

- Scoop (92%):

```sh
scoop install extras/twine
```

  Evidence: Scoop official bucket manifest trees: bucket/twine.json from https://api.github.com/repos/ScoopInstaller/Extras/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id ChrisKlimas.Twine -e
```

  Evidence: Windows Package Manager source index: ChrisKlimas.Twine from https://cdn.winget.microsoft.com/cache/source.msix

## Package facts

- **Package key:** brew:twine
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/twine>
- **Version:** 6.2.0
- **Source summary:** Utilities for interacting with PyPI
- **Homepage:** <https://github.com/pypa/twine>
- **Repository:** <https://github.com/pypa/twine>
- **Upstream docs:** <https://twine.readthedocs.io/en/stable>
- **License:** Apache-2.0
- **Source archive:** <https://files.pythonhosted.org/packages/e0/a8/949edebe3a82774c1ec34f637f5dd82d1cf22c25e963b7d63771083bbee5/twine-6.2.0.tar.gz>
- **Last updated:** 2026-05-15T11:13:54Z
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- twine (cli)
- twine (alias)

## Dependencies

- certifi
- python@3.14

## Build dependencies

- rust

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 6.2.0
- Package-manager updated: 2026-05-15
- Local data: ok
- Upstream repository: https://github.com/pypa/twine
- info: No cached GitHub release or tag data was available.
## Project history and usage

Twine is the Python Packaging Authority's command-line utility for uploading Python distribution artifacts to PyPI and compatible repositories. It became the standard small tool between `python -m build` and a public package release.

### Project history

Twine was created to separate package building from package uploading and to make PyPI uploads safer and more testable. Its documentation contrasts it with `python setup.py upload`, emphasizing verified HTTPS, uploading already-built artifacts, and support for wheels and source distributions.

The changelog records a long-running 1.x series through the 2010s, a 2.0 release in 2019 that required Python 3.6 or later, 3.x releases that improved non-interactive and keyring behavior, and modern 5.x/6.x work around metadata validation, PyPI token handling, trusted publishing, and removal of older distribution formats.

### Adoption history

Twine's adoption tracks the modernization of Python packaging. As PyPI, Warehouse, wheels, API tokens, and build-system-independent packaging became normal, Twine became the familiar upload command in release checklists, CI jobs, and packaging tutorials.

Its package-manager presence is broad: the input facts show it packaged by Homebrew, Debian, Ubuntu, Fedora/dnf, Arch/pacman, MacPorts, Nix, Scoop, and other ecosystems. That breadth reflects its role as infrastructure for publishing other packages, not as an end-user application.

### How it is used

The standard workflow is to build distributions, test against TestPyPI if needed, and run `twine upload dist/*`. Twine can read repository and credential information from `.pypirc` or environment variables, prompt interactively, and upload source distributions, wheels, signatures, and newer attestations depending on version.

Package maintainers also use `twine check` to validate distribution metadata and README rendering before upload. In CI, Twine is commonly configured with tokens, trusted publishing, or repository URLs for private Python indexes.

### Why package nerds care

Twine is package-nerd infrastructure in the purest sense: it exists so other packages can be published predictably. It codified the split between build artifacts and upload transport, which made Python release automation easier to audit and script.

It also captures the Python ecosystem's security migration: away from legacy `setup.py upload` workflows and toward HTTPS, API tokens, keyring integration, metadata validation, and trusted publishing.

### Timeline

- 2010s: Twine 1.x establishes the build-then-upload PyPI workflow.
- 2019-09-24: Twine 2.0.0 requires Python 3.6 or later.
- 2019-2022: Twine 3.x and 4.x improve authentication, non-interactive use, metadata handling, and modern Python support.
- 2024-2025: Twine 5.x and 6.x remove older formats and add work around token defaults, trusted publishing, and refreshed short-lived tokens.

### Related projects

- PyPI and Warehouse are Twine's primary public upload targets.
- `python -m build`, setuptools, wheels, and source distributions form the artifact side of the workflow Twine uploads.
- The Python Packaging User Guide and PyPA recommendations helped make Twine part of standard Python release practice.

### Sources

- Official GitHub repository: https://github.com/pypa/twine
- Official changelog: https://twine.readthedocs.io/en/stable/changelog.html
- Official documentation: https://twine.readthedocs.io/en/stable/
- PyPI project page: https://pypi.org/project/twine/


## Security Notes

No matching local secret-handling manifest was found for twine. Nucleus package metadata is still published here so future coverage has a stable package URL.



## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ~/.pypirc

## Credential files

- Unix: ~/.pypirc
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** twine
- **Version Scheme:** 0
- **Revision:** 6
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Debian apt - twine - 6.1.0-1: normalized package name match | Debian stable package indexes: twine from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | utility for interacting with PyPI | https://github.com/pypa/twine
- Nix - twine: normalized package name match | nixpkgs package indexes: twine from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - twine - 5.0.0-1: normalized package name match | Ubuntu 24.04 LTS package indexes: twine from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | utility for interacting with PyPI | https://github.com/pypa/twine
- apk - twine - 6.1.0-r1: normalized package name match | Alpine Linux edge package indexes: twine from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Collection of utilities for publishing packages on PyPI | https://twine.readthedocs.io/en/latest/
- apk - twine-pyc - 6.1.0-r1: normalized package name match | Alpine Linux edge package indexes: twine-pyc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Precompiled Python bytecode for twine | https://twine.readthedocs.io/en/latest/
- dnf - twine - 6.2.0-7.fc45: normalized package name match | Fedora Rawhide package metadata: twine from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | Twine is a utility for publishing Python packages on PyPI | https://github.com/pypa/twine
- pacman - twine - 6.2.0-3: normalized package name match | Arch Linux sync databases: twine from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | Collection of utilities for interacting with PyPI | https://github.com/pypa/twine/
- MacPorts - twine: normalized package name match | MacPorts ports tree: python/twine/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Scoop - extras/twine: normalized package name match | Scoop official bucket manifest trees: bucket/twine.json from https://api.github.com/repos/ScoopInstaller/Extras/git/trees/master?recursive=1
- winget - ChrisKlimas.Twine: normalized package name match | Windows Package Manager source index: ChrisKlimas.Twine from https://cdn.winget.microsoft.com/cache/source.msix


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Package publisher tools](https://www.automicvault.com/pkg/package-publishers/) - Belongs to a package publishing or registry command family.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [python@3.14](https://www.automicvault.com/pkg/brew/python-3-14/) - Runtime dependency declared by Homebrew.
- [rust](https://www.automicvault.com/pkg/brew/rust/) - Build dependency declared by Homebrew.
- [grayskull](https://www.automicvault.com/pkg/brew/grayskull/) - Shares av.db curated category or tags: cli, developer-tools, package-management, packaging, python.
- [pdm](https://www.automicvault.com/pkg/brew/pdm/) - Shares av.db curated category or tags: cli, developer-tools, package-management, packaging, python.
- [poetry](https://www.automicvault.com/pkg/brew/poetry/) - Shares av.db curated category or tags: cli, developer-tools, package-management, packaging, python.
- [brew-gem](https://www.automicvault.com/pkg/brew/brew-gem/) - Shares av.db curated category or tags: cli, developer-tools, package-management, packaging.
- [conan](https://www.automicvault.com/pkg/brew/conan/) - Shares av.db curated category or tags: cli, developer-tools, package-management, python.
- [conda-lock](https://www.automicvault.com/pkg/brew/conda-lock/) - Shares av.db curated category or tags: cli, developer-tools, package-management, python.
- [flit](https://www.automicvault.com/pkg/brew/flit/) - Shares av.db curated category or tags: cli, developer-tools, packaging, pypi, python.
- [pipx](https://www.automicvault.com/pkg/brew/pipx/) - Shares av.db curated category or tags: cli, developer-tools, package-management, python.
- [pipenv](https://www.automicvault.com/pkg/brew/pipenv/) - Both packages touch the same language runtime or ecosystem. Shared terms: certifi, cli, developer, developer-tools, management.
- [abi3audit](https://www.automicvault.com/pkg/brew/abi3audit/) - Both packages touch the same language runtime or ecosystem. Shared terms: certifi, cli, developer, developer-tools, packaging.

## Combined YAML source

View the package source record on GitHub. [combined/twine.yml](https://github.com/automic-vault/db/blob/main/combined/twine.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
