How To Install golang-github-spf13-cobra on Fedora 36

In this tutorial we learn how to install golang-github-spf13-cobra in Fedora 36. golang-github-spf13-cobra is Commander for modern Go CLI interactions

Introduction

In this tutorial we learn how to install golang-github-spf13-cobra on Fedora 36.

What is golang-github-spf13-cobra

Cobra is a library providing a simple interface to create powerful modern CLI interfaces similar to git & go tools. Cobra is also an application that will generate your application scaffolding to rapidly develop a Cobra-based application. Cobra provides - Easy subcommand-based CLIs - Fully POSIX-compliant flags (including short & long versions) - Nested subcommands - Global, local and cascading flags - Easy generation of applications & commands with cobra init appname & cobra add cmdname - Intelligent suggestions (app srver… did you mean app server?) - Automatic help generation for commands and flags - Automatic help flag recognition of -h, –help, etc. - Automatically generated bash autocomplete for your application - Automatically generated man pages for your application - Command aliases so you can change things without breaking them - The flexibility to define your own help, usage, etc. - Optional tight integration with viper for 12-factor apps

We can use yum or dnf to install golang-github-spf13-cobra on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install golang-github-spf13-cobra.

Install golang-github-spf13-cobra on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install golang-github-spf13-cobra using dnf by running the following command:

sudo dnf -y install golang-github-spf13-cobra

Install golang-github-spf13-cobra on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install golang-github-spf13-cobra using yum by running the following command:

sudo yum -y install golang-github-spf13-cobra

How To Uninstall golang-github-spf13-cobra on Fedora 36

To uninstall only the golang-github-spf13-cobra package we can use the following command:

sudo dnf remove golang-github-spf13-cobra

golang-github-spf13-cobra Package Contents on Fedora 36

/usr/bin/cobra
/usr/lib/.build-id
/usr/lib/.build-id/61
/usr/lib/.build-id/61/50311f84091fb5baf83e4bbac30272c288e25a
/usr/share/doc/golang-github-spf13-cobra
/usr/share/doc/golang-github-spf13-cobra/CHANGELOG.md
/usr/share/doc/golang-github-spf13-cobra/CONDUCT.md
/usr/share/doc/golang-github-spf13-cobra/CONTRIBUTING.md
/usr/share/doc/golang-github-spf13-cobra/README-cobra.md
/usr/share/doc/golang-github-spf13-cobra/README.md
/usr/share/doc/golang-github-spf13-cobra/bash_completions.md
/usr/share/doc/golang-github-spf13-cobra/doc
/usr/share/doc/golang-github-spf13-cobra/doc/README.md
/usr/share/doc/golang-github-spf13-cobra/doc/cmd_test.go
/usr/share/doc/golang-github-spf13-cobra/doc/man_docs.go
/usr/share/doc/golang-github-spf13-cobra/doc/man_docs.md
/usr/share/doc/golang-github-spf13-cobra/doc/man_docs_test.go
/usr/share/doc/golang-github-spf13-cobra/doc/man_examples_test.go
/usr/share/doc/golang-github-spf13-cobra/doc/md_docs.go
/usr/share/doc/golang-github-spf13-cobra/doc/md_docs.md
/usr/share/doc/golang-github-spf13-cobra/doc/md_docs_test.go
/usr/share/doc/golang-github-spf13-cobra/doc/rest_docs.go
/usr/share/doc/golang-github-spf13-cobra/doc/rest_docs.md
/usr/share/doc/golang-github-spf13-cobra/doc/rest_docs_test.go
/usr/share/doc/golang-github-spf13-cobra/doc/util.go
/usr/share/doc/golang-github-spf13-cobra/doc/yaml_docs.go
/usr/share/doc/golang-github-spf13-cobra/doc/yaml_docs.md
/usr/share/doc/golang-github-spf13-cobra/doc/yaml_docs_test.go
/usr/share/doc/golang-github-spf13-cobra/fish_completions.md
/usr/share/doc/golang-github-spf13-cobra/powershell_completions.md
/usr/share/doc/golang-github-spf13-cobra/projects_using_cobra.md
/usr/share/doc/golang-github-spf13-cobra/shell_completions.md
/usr/share/doc/golang-github-spf13-cobra/user_guide.md
/usr/share/doc/golang-github-spf13-cobra/zsh_completions.md
/usr/share/licenses/golang-github-spf13-cobra
/usr/share/licenses/golang-github-spf13-cobra/LICENSE.txt

References

Summary

In this tutorial we learn how to install golang-github-spf13-cobra on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).