[GRASS-git] [OSGeo/grass] 14923e: grass.app: Add mapset create subcommand (#6462)
Vaclav Petras
noreply at github.com
Mon Oct 6 07:20:32 PDT 2025
Branch: refs/heads/main
Home: https://github.com/OSGeo/grass
Commit: 14923ee67d9fc6e63e602efbc8ed57742bb07aab
https://github.com/OSGeo/grass/commit/14923ee67d9fc6e63e602efbc8ed57742bb07aab
Author: Vaclav Petras <wenzeslaus at gmail.com>
Date: 2025-10-06 (Mon, 06 Oct 2025)
Changed paths:
M python/grass/app/cli.py
M python/grass/app/tests/grass_app_cli_test.py
M python/grass/grassdb/create.py
Log Message:
-----------
grass.app: Add mapset create subcommand (#6462)
For symmetry with project create, this adds a new mapset create subcommand. The mapset subcommand can be used, similarly to project, to group operations related to mapsets.
Locking will be moved under mapset in #6437, so besides the availability of the subcommand for testing of other subcommands, the move of locking is the main motivation for adding the mapset create subcommand now.
The mapset creation uses the semi-internal function grass.grassdb.create.create_mapset. The function parameters were adjusted to allow for a single path being provided (which was already supported through path resolution function, but not supported though the parameters).
There are no parameters yet, and only basic creation and creation failure are handled (no computational region, overwrite, or search path). Tests cover creation and basic expectations of the new mapset, that is being separate from the default mapset, but part of the project.
Example: python -m grass.app mapset create data/project/task_1
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