version

package
v1.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 16, 2026 License: Apache-2.0 Imports: 0 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package version holds the CLI's wire identity: its product token and the single version string.

Index

Constants

View Source
const Product = "digitalx-cli"

Product is the product token identifying this CLI on the wire — the first half of the User-Agent's leading "<product>/<version>" pair. It is the PRODUCT's name, deliberately independent of the invoked command name (internal/progname): server-side traffic attributes to one client whichever of the binary's names a user typed.

Variables

View Source
var Version = "dev"

Version is the CLI version — reported by `--version`, embedded in the User-Agent header, and published in the commands catalog. It is injected at release build time via the linker:

-ldflags "-X github.com/digitalx-official/digitalx-cli/internal/version.Version=<tag>"

(the release pipeline feeds it the git tag). A plain `go build` / `go run` from source leaves the "dev" default. It is therefore a var, not a const: `-X` can only overwrite a string variable.

Functions

func Token

func Token() string

Token is the "<product>/<version>" pair the User-Agent leads with — the single source of that string, so the wire layer's default, the WebSocket dial default, and the rich composed value in internal/useragent cannot drift apart.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL