EC_NULL_LOG( volumes = getvolumes() );
for (vol = volumes; vol; vol = vol->v_next) {
- bstring volnamequot = bformat("'%s'", vol->v_path);
- bstrListPush(vollist, volnamequot);
+ if (vol->v_flags & AFPVOL_SPOTLIGHT) {
+ bstring volnamequot = bformat("'%s'", vol->v_path);
+ bstrListPush(vollist, volnamequot);
+ }
}
volnamelist = bjoin(vollist, sep);
Keep in sync with libatalk/util/volinfo.c
*/
#define AFPVOL_NOV2TOEACONV (1 << 5) /* no adouble:v2 to adouble:ea conversion */
+#define AFPVOL_SPOTLIGHT (1 << 6) /* Index volume for Spotlight searches */
#define AFPVOL_RO (1 << 8) /* read-only volume */
#define AFPVOL_NOSTAT (1 << 16) /* advertise the volume even if we can't stat() it
* maybe because it will be mounted later in preexec */
volume->v_flags |= AFPVOL_NOV2TOEACONV;
if (getoption_bool(obj->iniconfig, section, "follow symlinks", preset, 0))
volume->v_flags |= AFPVOL_FOLLOWSYM;
+ if (getoption_bool(obj->iniconfig, section, "spotlight", preset, 0))
+ volume->v_flags |= AFPVOL_SPOTLIGHT;
if (getoption_bool(obj->iniconfig, section, "preexec close", preset, 0))
volume->v_preexec_close = 1;