Skip to main content

Simple command-line utility that converts Makefiles to Markdown if specific commenting style is followed.

Project description

Makefile to Markdown

Coverage

Overview

Simple command-line utility that converts Makefiles to Markdown if specific commenting style is followed.

Headers

Headers (sections) should look like this:

# -----------------------------------------------------------------------------
# Header Name
# -----------------------------------------------------------------------------

Commands

Commands should look like this:

command:  ## Command description
	echo "do something"

Example Makefile

# -----------------------------------------------------------------------------
# Testing
# -----------------------------------------------------------------------------

pytest:  ## Run tests
	pytest -vx

pytest_verbose:  ## Run tests in verbose mode
	pytest -vvs

coverage:  ## Run tests with coverage
	coverage run -m pytest && coverage html

coverage_verbose:  ## Run tests with coverage in verbose mode
	coverage run -m pytest -vss && coverage html

coverage_skip:  ## Run tests with coverage and skip covered
	coverage run -m pytest -vs && coverage html --skip-covered

open_coverage:  ## Open coverage report
	open htmlcov/index.html

# -----------------------------------------------------------------------------
# Ruff
# -----------------------------------------------------------------------------

ruff_format: ## Run ruff format
	ruff format src/env_secret_extractor

ruff_check: ## Run ruff check
	ruff check src/env_secret_extractor

ruff_clean: ## Run ruff clean
	ruff clean

Installation

python3 -m pip install makefile-to-markdown

Usage

makefile-to-markdown convert --path "Makefile"

Development

make env
make pip_install
make pip_install_editable

Testing

make pytest
make coverage
make open_coverage

Issues

If you experience any issues, please create an issue on Github.

Not Exactly What You Want?

This is what I want. It might not be what you want. If you have differences in your preferred setup, I encourage you to fork this to create your own version.

History

All notable changes to this project will be documented in this file. This project adheres to Semantic Versioning.

0.1.1 (2024-04-23)

  • Moved from argparse to click

0.1.0 (2024-04-16)

  • First release

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

makefile_to_markdown-0.1.1.tar.gz (8.8 kB view hashes)

Uploaded Source

Built Distribution

makefile_to_markdown-0.1.1-py3-none-any.whl (5.9 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