On the filamentary environment of galaxies