From f822ed4335bcb8352d7cb898c10d6752982ad05e Mon Sep 17 00:00:00 2001 From: Armaan Bhojwani Date: Mon, 5 Jul 2021 13:11:01 -0400 Subject: [PATCH] fmt: add script --- fmt | 3 +++ man/fmt.1.scd | 15 +++++++++++++++ 2 files changed, 18 insertions(+) create mode 100755 fmt create mode 100644 man/fmt.1.scd diff --git a/fmt b/fmt new file mode 100755 index 0000000..71c95ac --- /dev/null +++ b/fmt @@ -0,0 +1,3 @@ +#!/usr/bin/env sh + +awk '/^$/ {print} /./ {printf("%s ", $0)} END {print ""} ' | fold -s $@ diff --git a/man/fmt.1.scd b/man/fmt.1.scd new file mode 100644 index 0000000..305839f --- /dev/null +++ b/man/fmt.1.scd @@ -0,0 +1,15 @@ +fmt-music(1) + +# NAME +fmt - a fake fmt implementaion + +# SYNOPSIS +*fmt* [file to format] + +# DESCRIPTION +A fake fmt implementation using fold and awk, for coreutils that don't come +with an fmt implementation. + +# COPYRIGHT +This is free and unencumbered software released into the public domain. For more +information, please refer to . \ No newline at end of file -- 2.39.2