How to ignore files for Cloud Backups?

What issue or error are you experiencing?

Can not figure out the path needed to ignore files in my theme folder. Local wants to backup my node_modules folder and a lot of other stuff.

This is what I added to my .localbackupaddonignore.txt file under the **/.git line:

**/.git

# Ignore specific folders and files in your theme
app/public/wp-content/themes/understrap-child-1.1.0/dist/
app/public/wp-content/themes/understrap-child-1.1.0/node_modules

I think the instructions on this file say that it can use either Restic or Git by default, but obviously something is wrong. Perhaps my file paths are not correct? I created the paths based on where these folders were in relation to the .localbackupaddonignore.txt file


What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc


System Details

  • Local Version:

  • Version 9.0.5+6706

  • Operating System (OS) and OS version:

  • Mac OS Monterey


Local Logs

Attach your Local Logs here (Help Doc - Retrieving Local’s Log)
local-lightning.log (159.1 KB)


Security Reminder
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.

I think the Backups addon is looking for .localbackupaddonignore.txt at the web root of the site. So you’ll want to add that file to:

~/Local Sites/<sitename>/app/public/.localbackupaddonignore.txt

And then reference the ignored files like:

wp-content/themes/understrap-child-1.1.0/dist/
wp-content/themes/understrap-child-1.1.0/node_modules

One other option might be to just have dist and node_modules by themselves. I haven’t tried this myself, but I think that would ignore those folders, with the caveat that it would ignore ALL instances of those folders.

Can you give that a try and let us know how it goes?

2 Likes

Thank you, I will give that a shot! I’ll update the thread to let future searchers know if it worked or not.

2 Likes