[GRASS-git] [OSGeo/grass] 8bf604: g.mapsets: Add JSON output (#2542)

Corey White noreply at github.com
Thu Apr 11 04:56:52 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/OSGeo/grass
  Commit: 8bf604c6447ab705907c47fa595079716f27226f
      https://github.com/OSGeo/grass/commit/8bf604c6447ab705907c47fa595079716f27226f
  Author: Corey White <smortopahri at gmail.com>
  Date:   2024-04-11 (Thu, 11 Apr 2024)

  Changed paths:
    M general/g.mapsets/Makefile
    M general/g.mapsets/g.mapsets.html
    M general/g.mapsets/list.c
    M general/g.mapsets/local_proto.h
    M general/g.mapsets/main.c
    A general/g.mapsets/tests/conftest.py
    A general/g.mapsets/tests/g_mapsets_list_format_test.py

  Log Message:
  -----------
  g.mapsets: Add JSON output (#2542)

* g.mapsets: fixed indenting and added json flag  in preperation to add json output

* Added format options to list mapsets as plain, vertical, csv, or json

* g.mapsets: Added start testing listing mapsets with different formats

* g.mapsets: Reformated python with flake8 and black

* g.mapsets: Fixed indent conflict

* Fixed implicit declaration of function errors

* Fixed issues found in code review

* Added print flag to json output and added tests

* Simplified tests

* Apply clang format suggestions

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Updated code to use parson and fixed tests

* Updated docs

* Fixed mapsets array initalization issue

* Fixed bug setting JSON_ARRAY

* Removed unused parameter

* Update general/g.mapsets/main.c

Fixed typo.

Co-authored-by: Anna Petrasova <kratochanna at gmail.com>

* Updated default separator to space

* Update general/g.mapsets/main.c

Switch GUI section to Print

Co-authored-by: Anna Petrasova <kratochanna at gmail.com>

* Update general/g.mapsets/main.c

Co-authored-by: Anna Petrasova <kratochanna at gmail.com>

* Update general/g.mapsets/main.c

Co-authored-by: Anna Petrasova <kratochanna at gmail.com>

* Removed unneeded logic

* Update general/g.mapsets/list.c

Co-authored-by: Nicklas Larsson <n_larsson at yahoo.com>

* Update general/g.mapsets/list.c

Co-authored-by: Nicklas Larsson <n_larsson at yahoo.com>

* Implmented suggestion from code review

* Removed duplicate code

* Refactored duplicate code and removed some comments

---------

Co-authored-by: Edouard Choinière <27212526+echoix at users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Corey White <ctwhite48 at gmail.com>
Co-authored-by: Anna Petrasova <kratochanna at gmail.com>
Co-authored-by: Nicklas Larsson <n_larsson at yahoo.com>



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