g.remove(1grass)
β¨ g.remove β¨
okay bestie, welcome to the g.remove page from the GRASS User's Manual (that's g.remove(1grass) if you're being formal π
). This is the one that deletes data base element files out of your current mapset using a search pattern. Big main character energy. Cleaning up your mapset is self care, fr fr π§Ήβ¨
πΈ KEYWORDS πΈ
general, map management, remove
like... the vibe is literally in the keywords. it's giving "spring cleaning" π¦
π SYNOPSIS π
g.remove
g.remove --help
g.remove [-irefb] type=datatype[,datatype,...] [name=string[,string,...]] [ignore=string[,string,...]] [pattern=string] [exclude=string] [--help] [--verbose] [--quiet] [--ui]
π Flags π
-iβ ignore case, bestie.TMP_1andtmp_1are the same girl now π-rβ use basic regular expressions instead of wildcards-eβ use extended regular expressions instead of wildcards-fβ force removal β and like, this one is not optional-optional, it's required for actual deletion of files π no-f, no delete, that's the rule-bβ remove base raster maps--helpβ print usage summary--verboseβ verbose module output--quietβ quiet module output--uiβ force launching GUI dialog
π¦ Parameters π¦
type=datatype[,datatype,...][required] β the data type(s), you have to tell her what to remove- Options:
raster,raster_3d,vector,label,region,group,all raster: raster map(s)raster_3d: 3D raster map(s)vector: vector map(s)label: paint label file(s)region: region definition(s)group: imagery group(s)all: all types
- Options:
name=string[,string,...]β name of file(s) to remove, just say their names bestieignore=string[,string,...]β name of file(s) to ignore (default: none)pattern=stringβ file name search pattern π΅οΈexclude=stringβ file name exclusion pattern (default: none)
π DESCRIPTION π
so g.remove removes data files matching a pattern β and that pattern can be given by wildcards or POSIX Extended Regular Expressions. she's flexible like that β¨
but here's the plot twist that saves your whole life: if the -f force flag is not given, then nothing is removed. instead, the list of selected file names gets printed to stdout as a preview of the files that would be deleted. it's a vibe check before the actual vibe check. literally the safest energy. so you can peek at what's about to get deleted before you commit πβ‘οΈπ«Ά
π₯ EXAMPLES π₯
Delete map1 and map2 raster maps in the current mapset:
g.remove -f type=raster name=tmp1,tmp2
Delete all raster and vector maps starting with "tmp_" in the current mapset:
# show matching raster and vector maps but do not delete yet (as verification)
g.remove type=raster,vector pattern="tmp_*"
# actually delete the matching raster and vector maps
g.remove -f type=raster,vector pattern="tmp_*"
Delete all vector maps starting with "stream_" in the current mapset, but exclude those ending with "_final":
g.remove -f type=vector pattern="stream_*" exclude="*_final"
see how the first tmp_ one runs without -f first?? that's the "look before you leap" moment and honestly it ate π
π AUTHOR π
Huidae Cho grass4u@gmail.com
β SOURCE CODE β
Available at: g.remove source code (history)
Latest change: Thursday May 08 14:35:40 2025 in commit: 9528b1e38ba37992c1597a979dc3efbb07b74ec5
Main index | General index | Topics index | Keywords index | Graphical index | Full index
and that's the whole page bestie π«ΆΒ© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual, GRASS 8.5.0, g.remove(1grass) β slay, go clean that mapset, but run it without -f first, iykyk π
πΈ
π¦ where this page comes from
- alpine 3.24: grass-gis-doc 8.5.0-r1 Β· GPL-2.0-or-later
- ubuntu stonking: grass-doc 8.5.0-1ubuntu1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms