Giter Site home page Giter Site logo

zacharyburnett / peppyproject Goto Github PK

View Code? Open in Web Editor NEW
8.0 8.0 0.0 122 KB

move Python project configuration from `setup.cfg` and `setup.py` to a PEP621-compliant `pyproject.toml`

License: GNU General Public License v3.0

Python 100.00%
pep621 pyproject-toml python toml

peppyproject's Introduction

peppyproject

build pypi implementation python tests codecov Code style: black License: GPL v3

peppyproject creates a PEP621-compliant pyproject.toml file from an existing Python project's build configuration (setup.cfg, setup.py, tox.ini, pytest.ini, etc.).

Installation

pip install peppyproject

Usage

Caution

peppyproject uses ini2toml[full] to read setup.cfg and INI files, and ast.literal_eval() to read and parse a setup.py file. It assumes you have vetted the setup.py and does not perform any sanitization or safety checking; thus, it is inadvisable to use on unknown or potentially malicious setup.py scripts.

peppyproject . -o pyproject.toml
Usage: peppyproject [OPTIONS] [DIRECTORY]

  read a Python project configuration and output a PEP621-compliant `pyproject.toml`

Arguments:
  [DIRECTORY]  directory from which to read configuration

Options:
  -o, --output PATH  path to which to write TOML
  --help             Show this message and exit.

API

from peppyproject import PyProjectConfiguration

configuration = PyProjectConfiguration.from_directory('./my_python_project')
configuration.to_file('./my_python_project/pyproject.toml')

peppyproject's People

Contributors

zacharyburnett avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

peppyproject's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.