• Resolved franfoto

    (@franfoto)


    I have a directory with a staging installation. I have included the.donotbackup file in the folder of this directory, but it is still making a backup of this directory. Do I have to put this file in all the folders included in it?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author David Anderson

    (@davidanderson)

    Hi,

    That won’t prevent a backup. It’ll just mean the backup doesn’t have much in it. (Though, you’d also have to put it in the root of each entity, not the overall install – i.e. wp-content/plugins/.donotbackup, wp-content/themes/.donotbackup).

    To prevent the backup itself, add something like this as an mu-plugin:

    add_filter('updraftplus_boot_backup', 'my_updraftplus_boot_backup');
    function my_updraftplus_boot_backup($go) {
    
      return (site_url() == 'https://url-of-dev-site') ? false : $go;
    
    }
    Thread Starter franfoto

    (@franfoto)

    Hi David,

    I’m sorry I answered so late. Until today I have no time to test it. I did what you told me and it works fine.

    Thanks for the code and help!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Using the .donotbackup file’ is closed to new replies.