Skip to main content

Never gonna give you up!

Project description

toml_cfg_tool

Table of Contents

Prerequisites

Description

A tool to create toml and cfg files for use in python projects, it can also simultaneously update aspects that are common between the two files.

Features

Arguments

The tool accepts the following arguments:

  • --show: Show the current configuration. (only shows the options that can be updated)
  • --author: Update the project author.
  • --name: Update the project name.
  • --version: Update the project version.
  • --description: Update the project description.
  • --requires-python: Update the required Python version.
  • --license: Update the project license.
  • --workflow_files: Add GitHub Actions workflow files, and scripts.
  • --create-templates: Create template setup.cfg and pyproject.toml files if they do not exist.
  • --backup: Backup existing configuration files before making changes.
  • --dry-run: Show changes without writing to files.

Examples

  • Show the current configuration:
toml_cfg_tool --show
  • Create template configuration files:
toml_cfg_tool --create-templates
  • Create the workflow files:
toml_cfg_tool --workflow_files
  • Show changes without writing to files:
toml_cfg_tool --dry-run --name "New Project Name" --author "New Project Author" --version "1.0.0" --description "New Project Description" --requires-python ">=3.6" --license "MIT"
  • Update the project version:
pip install toml_cfg_tool
  • Update the project name:
toml_cfg_tool --name "New Project Name"
  • Update the project author and backup existing files:
toml_cfg_tool --author "New Project Author" --backup path/to/backups.bak
  • Create template configuration files and workflow files while updating the project name, author, and version:
toml_cfg_tool --create-templates --workflow_files --name "New Project Name" --author "New Project Author" --version "1.0.0"

Screenshots

  • Show the current configuration (only shows the options that can be updated):

  • Create template configuration files:

Create the template .toml and .cfg files

  • Create the CONTRIBUTING.md file:

CONTRIBUTING.md

  • Update all available fields:

Installation and Setup

To install the tool, run the following command:

pip install toml_cfg_tool

To check if the tool is installed, run the following command:

pip show toml_cfg_tool

or

toml_cfg_tool --help

Run the application:

Any of the arguments can be used or excluded from the command below. The tool will only update the specified fields. - Use dry-run to see changes without writing to files - Use backup to backup existing files before making changes - Use create-templates to create template configuration files - Use workflow_files to create GitHub Actions workflow files

toml_cfg_tool --name "New Project Name" --author "New Project Author" --version "1.0.0" --description "New Project Description" --requires-python ">=3.6" --license "MIT"

Contributing

Contributing

License

This project is licensed under the MIT License. You can find the full text of the license in the LICENSE file.

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

toml_cfg_tool-0.0.6.tar.gz (9.3 kB view hashes)

Uploaded Source

Built Distribution

toml_cfg_tool-0.0.6-py3-none-any.whl (12.6 kB view hashes)

Uploaded Python 3

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