[GRASS-git] [OSGeo/grass] 5fbf52: r.info: Add JSON output (#3744)

Kriti Birda noreply at github.com
Sun Jun 16 03:48:47 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/OSGeo/grass
  Commit: 5fbf5263870131b0dbfc7e2431a1879720879c82
      https://github.com/OSGeo/grass/commit/5fbf5263870131b0dbfc7e2431a1879720879c82
  Author: Kriti Birda <164247895+kritibirda26 at users.noreply.github.com>
  Date:   2024-06-16 (Sun, 16 Jun 2024)

  Changed paths:
    M raster/r.info/Makefile
    M raster/r.info/main.c
    M raster/r.info/r.info.html
    M raster/r.info/testsuite/test_r_info.py

  Log Message:
  -----------
  r.info: Add JSON output (#3744)

Uses parson to add JSON output format support to the r.info module. The tool has various flags to control the fields being output in case of the shell script style format (aka plain in the code). The JSON output always contains all fields even without the flags being specified, except for statistics. The statistics must be set with a flag because the statistics are only optionally stored in the raster data and computing them on the fly takes a lot of time.

The option value for format is plain (shell/key-value) and json and internally, the plain, human output is treated separately from the machine readable formats which are PLAIN and JSON.



To unsubscribe from these emails, change your notification settings at https://github.com/OSGeo/grass/settings/notifications


More information about the grass-commit mailing list