Skip to main content

A CLI for extracting python metadata from packages

Project description

mddj

Your DJ of MetaData.

PyPI - Version PyPI - Python Version


Table of Contents

Overview

A CLI for interacting with your python package metadata.

Supports multiple packaging backends via a uniform interface.

Installation

pipx install mddj

Usage

Env Vars

Build Isolation

MDDJ_ISOLATED_BUILDS=0 can be set to disable the (default) behavior using isolated build environments when getting package metadata.

This requires that you have installed all of the build-system requirements in to the current environment, but will be much faster.

Commands

See --help on each command for more detail on supported options.

mddj self version

Show the version of mddj.

mddj read requires-python

Show the requires_python field.

mddj read version

Show the version.

mddj read tox min-version

Show the minimum python version in the tox env_list.

mddj read tox list-versions

Show all python versions in the tox env_list.

mddj write version

Write a new version to a target file, defaulting to a version = ... assignment in pyproject.toml.

Supports configuration via pyproject.toml.

Config

Configuration for mddj can only be read from a tool.mddj table in pyproject.toml. No other configuration sources are supported.

write_version

This setting controls how version information is written for mddj write version.

It takes a colon delimited string with two or three values. Either {mode}:{path}:{key} or {mode}:{key}.

The only supported {mode} is "assign" (for now). {path} defaults to pyproject.toml if omitted. {key} is the name of the attribute used to assign a value.

This defaults to assign: version.

For example, the following config can be used to target a __version__ attribute in an __init__.py file in a src-layout project:

[tool.mddj]
write_version = "assign: src/foopkg/__init__.py: __version__"

License

mddj is distributed under the terms of the MIT license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mddj-0.0.7.tar.gz (9.4 kB view details)

Uploaded Source

Built Distribution

mddj-0.0.7-py3-none-any.whl (11.9 kB view details)

Uploaded Python 3

File details

Details for the file mddj-0.0.7.tar.gz.

File metadata

  • Download URL: mddj-0.0.7.tar.gz
  • Upload date:
  • Size: 9.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.5

File hashes

Hashes for mddj-0.0.7.tar.gz
Algorithm Hash digest
SHA256 a31ca414306cd6c26be5a382d3fac8cbb5327e86e71c3832479f3184d34121a0
MD5 7112b6169122d8328e120dbb28031df5
BLAKE2b-256 c174e6d1fb4743833181483b87faa80e213ffe9ccb8080b735d6183488ca557a

See more details on using hashes here.

Provenance

File details

Details for the file mddj-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: mddj-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 11.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.5

File hashes

Hashes for mddj-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 2a05e0cb7f85d92bcafec2087598e364e97c946c2da1d50ddde1da24ef58ffa0
MD5 8ce48703f59957a31c2d755a9b9e9beb
BLAKE2b-256 598d6867035af712e76abb5e5f18e1b56380e7ef1cbc91645fcac628a9231536

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page