netzbasis / knfmt

kernel normal form formatter

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

knfmt

The knfmt(1) utility formats source code files according to style(9) from OpenBSD. By default, source code is read from standard input and the formatted source code is written to standard output:

$ knfmt <knfmt.c

It can perform an in place edit by writing back the formatted source code:

$ knfmt -i knfmt.c

It can produce a diff between the original and formatted source code:

$ knfmt -d knfmt.c

The implementation is further described in DESIGN.

Installation

From source

The installation prefix defaults to /usr/local and can be altered using the PREFIX environment variable when invoking configure:

$ ./configure
$ make install

License

Copyright (c) 2021 Anton Lindqvist. Distributed under the ISC license.

About

kernel normal form formatter

License:ISC License


Languages

Language:C 96.0%Language:Makefile 3.5%Language:Shell 0.3%Language:Roff 0.2%