Skip to main content

Bench Version

The bench version command displays version information for all applications installed in the current Bench. It helps administrators verify installed app versions, branches, and commit hashes for troubleshooting, upgrades, and environment validation.

Tip:

Use the JSON format when integrating Bench output into automation scripts or CI/CD pipelines.

Usage

bench version [OPTIONS]

Available Output Formats

The command supports multiple output formats depending on your requirements.

  • legacy (Default) – Displays the standard Bench version output.
  • plain – Human-readable version information with commit hashes.
  • table – Displays version information in an ASCII table.
  • json – Outputs version details in JSON format for scripting.

Command Option

Option Description
-f, --format Choose the output format. Supported values are plain, table, json, and legacy.

Output Examples

Plain Format

Displays version, branch, and commit information in a readable format.

bench version --format plain

erpnext 14.0.3 version-14 (4e88dcf)
frappe 14.0.1 version-14 (f8ec3d7)

JSON Format

Useful for automation, integrations, and scripting.

bench version --format json

[
  {
    "app": "erpnext",
    "branch": "version-14",
    "commit": "4e88dcf",
    "version": "14.0.3"
  },
  {
    "app": "frappe",
    "branch": "version-14",
    "commit": "f8ec3d7",
    "version": "14.0.1"
  }
]

Table Format

Displays application versions in a structured ASCII table.

bench version --format table

+-----------+---------+-------------+---------+
| App       | Version | Branch      | Commit  |
+-----------+---------+-------------+---------+
| erpnext   | 14.0.3  | version-14  | 4e88dcf |
| frappe    | 14.0.1  | version-14  | f8ec3d7 |
+-----------+---------+-------------+---------+

Common Examples

Display Version Information in Plain Format

bench version --format plain

Shows the installed applications along with their versions, branches, and commit hashes.

Display Version Information in JSON Format

bench version --format json

Returns structured JSON output suitable for scripts and external tools.

Display Version Information in Table Format

bench version --format table

Displays installed application versions in an easy-to-read table.

Best Practice:

Run bench version before upgrading or reporting issues. Including the version, branch, and commit information helps identify compatibility problems and simplifies troubleshooting.

Rating: 0 / 5 (0 votes)