If we want to get information about a vector layer (shapefile for example) we could use ogrinfo:
ogrinfo -so myshapefile.shp mylayer
This returns a lot of pertinent information about the shapefile. Is it possible to return whether or not a spatial index exists? If so, can we access info about the spatial index?
Note: I realize it is trivial to open the folder containing the shapefile and looking for a .sbn or .sbx and so the question is specific to ogrinfo.