Exclude folder from indexing: .nomedia? or own file?

Hi all,

in Audio Player, I want to enable the feature to exclude a folder from indexing.

Gallery and Android Apps use ".nomedia"
does it make sense to go with the same? or go with an app specific like e.g. “.noAudio” to be able to separate content?

what do you think?

Would it make sense to use one file to allow/disallow indexing like the robots.txt. Could be a .noindex-file.

I wish Gallery used app specific file like .noImage, as an example: I don’t want to scan my Audio album covers into Gallery, same would go for home audio recordings I keep with home videos, that I wouldn’t want to scan into my Audio Library, etc, etc…

1 Like

you are completely correct.
development is currently in final testing.
we decided to go for “.noAudio” for exactly that reason.

Additionally, “.nomedia” has a lot of implications on other android applications

@art I totally agree with you. Using .nomedia in Gallery was a bad idea because it blocked all media in synced folders on Android devices, as @Rello wrote.

Audio Player uses .noaudio. In the Gallery app I have replaced .nomedia by .noimage so the synchronization does not affect the functionality on my Android device.


cc @oparoz for the .nomedia issue.

How does .nomedia affect sync on Android? To me it should prevent these files to show in Nextcloud Gallery and in the Android device’s own Gallery app

I don’t think it affects sync. It does however block Android’s internal Media Scans functionality, so it will not show up in Android’s Gallery app and won’t be indexed by Android’s media database (on your phone).
So this can be by design and meets the need of most users or you/we/whoever wants the files to show up in Media apps on Android phones. Therefor the cc.

1 Like

I want to decide on every device/ server whether to show audio, video, and images – or not. .nomedia hides the files on both, Nextcloud and Android. With different files I have a choice.

Example: A .nomedia file in Music folder hides cover art files in the Gallery but prevents the Music app on my Android device to play all the audio files I synchronized to it. Excluding the .nomedia file from synchronization is not the best solution.

To prevent side effects with other apps we (@Rello and I) have decided to take .noaudio instead of .nomedia. That’s the original topic of this thread.

.nomedia means in Android a hide of all media files.

say you have your music library. you put in a .nomedia in OC/NC to avoid all the little folder/cover.png to show up in the slideshows.
The effect is, that you will not be able to play the music on Android.

I think its too generic and can bring more problems than benefit. whats against using a dedicated .noimage or similar?

Why is that? Seems ideal to me. Keep the Nextcloud config files in Nextcloud.

The main problem I see is that you then need to include 3-4 empty files to get your Nextcloud to behave the way you want it to.
But of course, the real solution would be to do that in the database, as it’s a user’s choice not to display images from specific folders.

Nexant uses a .noindex file to prevent folders from indexing.