![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
git.sr.ht/~rj/sgr
Package sgr provides formatters to write ANSI escape sequences that can format and colorize text.
The package can be installed from the command line using the go tool. There are no dependencies beyond the standard library. Any version of Go should work.
go get git.sr.ht/~rj/sgr
Package documentation and examples are on Go Reference.
As a small introduction, the following snippet prints to the console using some bold text. You can experiment with the snippet on the go playground.
func main() {
// The formatter is responsible for deciding when and what escape
// codes to use. The call to NewFormatter will return a formatter
// suitable for use with standard out.
f := sgr.NewFormatter()
// Print some text with bold.
fmt.Println("Hello,", f.Bold("world!"))
}
To submit bug reports and suggestions, please use the issue tracker.
Discussions occur using the mailing list. The mailing list can also be used to submit patches.
This packages does not aim to support a complete list of SGR escape codes, either for all possible terminals or even as defined in the standard. The supported codes should be widely portable across many terminals and operating systems.
Windows: Terminals on windows will increasingly support ANSI escape sequences, but current support may be uneven. The legacy API for setting text attributes has been, if not deprecated, discouraged. Therefore, direct support for the legacy API is not planned. If older terminials must be supported, then go-colorable can be used.
BSD (c) Robert Johnstone
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.