Welcome to the Chipshot documentation

The Chipshot logo, with a soccer ball shooting up and away from the project name.

Chipshot helps you standardize headers in your source code. Its aim is to help ensure that all source files have excellent headers with accurate copyright and license information. If it can help you achieve your goals, then it will have done its job!

Example

Chipshot respects byte order marks, newlines, and document prologues (like hashbangs and XML declarations) when adding and updating headers. Its default configuration supports many different file types so it’s easy to get started with a minimal configuration file.

.chipshot.toml

[chipshot]
template = """
Copyright 2022-{{ year }} Company Name <oss@company.example>
SPDX-License-Identifier: MIT
"""

Headers will be rendered as comments based on the file extension.

Python

# Copyright 2022-2023 Company Name <oss@company.example>
# SPDX-License-Identifier: MIT

C

/*
 * Copyright 2022-2023 Company Name <oss@company.example>
 * SPDX-License-Identifier: MIT
 */

Getting Started

  • Default comment styles gallery

How-To Guides

Reference

  • Configuration file format

  • Pre-commit hooks

  • CLI options