Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
T

tml

> 开发工具
Open source

:rainbow::computer::art: A tiny markup language for terminal output. Makes formatting output in CLI apps easier!

746 stars0 likes0 views
WebsiteGitHub

About

:rainbow::computer::art: A tiny markup language for terminal output. Makes formatting output in CLI apps easier!

tml - Terminal Markup Language

A Go module (and standalone binary) to make the output of coloured/formatted text in the terminal easier and more readable.

You can use it in your Go programs, and bash etc. too.

Usage in Go

The output of coloured/formatted text is easy using the following syntax:

go
package main

import "github.com/liamg/tml"

func main() {
    tml.Printf("this text is red and the following is %s\n", "not red")
}

Usage in Bash

First, install tml:

Install Go and run the following command.

# For Go 1.16+
# Make sure that `$GOPATH/bin` is in your `$PATH`, because that's where this gets installed

go install github.com/liamg/tml/tml@latest

# For Go this text is red and the following is not red" | tml

Format

Each tag is enclosed in angle brackets, much like HTML.

You can nest tags as deeply as you like.

It's not required to close tags you've opened, though it can make for easier reading.

Available Tags

Foreground Colours

  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``

Background Colours

  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``

Attributes

  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``
  • ``

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Goclicli-appcolorscolours

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category开发工具
PricingOpen source

> Related tools

V
VS Code
流行的开源代码编辑器
G
Git
分布式版本控制系统
V
Vite
下一代前端构建工具