Menu

Feature Request: Adding .gitignore-like file(s) to manage exclusions

Help
2026-01-08
2026-01-09
  • Cal Williams

    Cal Williams - 2026-01-08

    Currently snapraid allows excluding items from within a single snapraid.conf file.

    For this feature, rather than supporting only a single centrally managed snapraid.conf file, other files deeper in the tree would also manage exclusions, similar to how git projects can have multiple .gitignore's.

    They could be named something like .snapignore to make them distinct from snapraid.conf, although the existing syntax makes sense to me.

    Sometimes it's more intuitive/desirable to place a ignore file in the ignored directory rather than in the root ignore file. E.g., I have a one-off program I'm running that with some files I'd like to ignore. I don't intend to keep it around forever and don't want to commit it to my snapraid.conf. So, if I could put a .snapignore in the directory it would cease to exist once I'm done with the program and my snapraid.conf remains clean.

     
  • Andrea Mazzoleni

    It’s a good idea! I’m adding it to the TODO.

    However, the name .snapignore can't be used, as it would conflict with the Ubuntu "snap" application ecosystem (they have also discussed using .snapignore). Maybe we can use .snapraidignore instead. It’s a bit longer, but it avoids the risk of conflicts and keeps things clear.

     
  • Cal Williams

    Cal Williams - 2026-01-09

    Sounds good to me. Thanks for taking a looking and your project!

     

Log in to post a comment.