[GRASS-dev] [GRASS GIS] #2409: last call for options keys consolidation

GRASS GIS trac at osgeo.org
Thu Dec 25 02:51:29 PST 2014


#2409: last call for options keys consolidation
----------------------------------+-----------------------------------------
 Reporter:  martinl               |       Owner:  grass-dev@…              
     Type:  task                  |      Status:  new                      
 Priority:  blocker               |   Milestone:  7.0.0                    
Component:  Default               |     Version:  unspecified              
 Keywords:  standardized options  |    Platform:  Unspecified              
      Cpu:  Unspecified           |  
----------------------------------+-----------------------------------------

Comment(by glynn):

 Replying to [comment:146 neteler]:

 > It would be very helpful to advertise the candidates here, like:
 {{{
 g.region rast=rastermap -p
 ERROR: g.region: Sorry, <rast=> is ambiguous. Choices: <raster>,
 <raster_3d>
 }}}
 >
 > Could that be implemented?

 Yes (although as part of a change which would also remove the ambiguity in
 that case).

 My intention is to modify the code which calls match_option()
 (set_option() and check_string()) to record which options are matched. If
 one option is a prefix of all of the others, the string will be considered
 to unambiguously match that option. If the match is ambiguous, we now have
 a list of which options matched, which can be used for the error message.

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/2409#comment:169>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list