How can I backup a file or directory as part of my installation?

asked 12 Sep '11, 08:29

Jake's gravatar image

Jake ♦♦
796222226235
accept rate: 98%


You can backup a file or directory using a <backupFile> action as in the following example:

<createBackupFile>
  <path>${installdir}/conf/myapp.conf</path>
</createBackupFile>

This action creates a new file or directory, named after the path specified, with the suffix .bak0. If a backup file with that name already exists, it will create a new one ending in .bak1 (or .bak2, etc.)

link

answered 12 Sep '11, 08:30

Jake's gravatar image

Jake ♦♦
796222226235
accept rate: 98%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×2

Asked: 12 Sep '11, 08:29

Seen: 1,215 times

Last updated: 12 Sep '11, 08:30