Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env python3
# coding=utf8
#
# Simple script to scale a KiCad footprint
# Usage:
# python kicad-resize-footprint.py <input.kicad_mod> <output.kicad_mod> <scale>
#
# Where scale is how much to scale (1 = 100%)
#
# Copyright (C) 2020, Uri Shaked.
@EdwardBetts
EdwardBetts / pprint_color.py
Last active June 13, 2024 05:36
Python pprint with color syntax highlighting for the console
from pprint import pformat
from typing import Any
from pygments import highlight
from pygments.formatters import Terminal256Formatter
from pygments.lexers import PythonLexer
def pprint_color(obj: Any) -> None:
"""Pretty-print in color."""