Skip to content

Remove file headers from your Swift source files and add new headers based on a template.

Notifications You must be signed in to change notification settings

paxos/swift-header-tool

Repository files navigation

SwiftHeaderTool

This tool can remove file headers from your Swift source files and add new headers based on a template.

Install

swift package experimental-install

Uninstall

swift package experimental-uninstall SwiftHeaderTool

Usage

Early version, do not use in production.

SwiftHeaderTool strip --path sourcedir
SwiftHeaderTool add --path sourcedir --template-path template.txt
SwiftHeaderTool replace --path sourcedir --template-path template.txt

Example Template

$figlet(HyperKit)

$filename

Made by paxos in $date

will turn into

//
// #     #                                 #    #
// #     #  #   #  #####   ######  #####   #   #   #  #####
// #     #   # #   #    #  #       #    #  #  #    #    #
// #######    #    #    #  #####   #    #  ###     #    #
// #     #    #    #####   #       #####   #  #    #    #
// #     #    #    #       #       #   #   #   #   #    #
// #     #    #    #       ######  #    #  #    #  #    #
//
// CommitsService.swift
// Made by paxos in Mar 14, 2024

About

Remove file headers from your Swift source files and add new headers based on a template.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages