Skip to content

moul/banner

banner

😄 ultra lightweight ascii-art generator

CI go.dev reference License GitHub release Go Report Card CodeFactor codecov GolangCI Made by Manfred Touron

Pure-go library to generate ASCII-art banners from text.

  • doesn't need any external dependencies
  • very lightweight footprint at the end in the generated binary
    • ~38kb with default build options
    • ~12kb with upx + binary strip
  • only one font available (small.flf)
    • incomplete alphabet (a-zA-Z.-_?)

Usage

import "moul.io/banner"

fmt.Println(banner.Inline("hey world."))
 _                                    _     _
| |_   ___  _  _   __ __ __ ___  _ _ | | __| |
| ' \ / -_)| || |  \ V  V // _ \| '_|| |/ _` | _
|_||_|\___| \_, |   \_/\_/ \___/|_|  |_|\__,_|(_)
            |__/

Install

Using go

$ go get -u moul.io/banner

Releases

See https://github.com/moul/banner/releases

License

© 2020 Manfred Touron

Licensed under the Apache License, Version 2.0 (LICENSE-APACHE) or the MIT license (LICENSE-MIT), at your option. See the COPYRIGHT file for more details.

SPDX-License-Identifier: (Apache-2.0 OR MIT)