1.0.2 • Published 6 years ago

wordpress-media-library-backup-js v1.0.2

Weekly downloads
3
License
MIT
Repository
github
Last release
6 years ago

Wordpress media library backup

Backup tool to download entire WordPress media library preserving directory structure.

WordPress offers a free export tool that allows exporting of posts, pages, comments, categories, and (only) metadata of media files.

This backup tool then takes that XML file as input and downloads all media files referenced in it using the <wp:attachment_url> tag.

The colour-coded processing states are as follows

  • DOWNLOADING: Download has started for the resource at this URL
  • DOWNLOADED: Download has finished
  • SKIPPED: Download for this resource was skipped (the local copy is newer)
  • NOT FOUND: The resource has been deleted on the remote server

The total download time is reported at the end of the backup process.

Here is a sample output

Sample output

Installation

To install, run

npm install --save wordpress-media-library-backup-js

Usage

To run the console application, issue the command

node backup.js <xml-file> <destination-directory>

The default values for xml-file and destination-directory are "export.xml" and "./backup", respectively.

Examples

node backup.js
node backup.js export.xml /home/username/wp-backup
node backup.js export.sample.xml C:/temp/wordpress-media-library
1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago