// REVERSE_ORDER
public BackupFiles(File file)
{
- this(file, ".v" + NUM_PLACEHOLDER, false, 4, 3, false);
+ this(file, ".bak" + NUM_PLACEHOLDER, false, 3, 3, false);
}
public BackupFiles(File file, String defaultSuffix, boolean defaultNoMax,
public boolean rollBackupFiles()
{
- // file doesn't yet exist or backups are not enabled
- if ((!file.exists()) || (!enabled) || (max < 0))
+ // file doesn't yet exist or backups are not enabled or template is null or
+ // empty
+ if ((!file.exists()) || (!enabled) || max < 0 || suffix == null
+ || suffix.length() == 0)
{
// nothing to do
return true;
}
- // split filename up to insert suffix template in the right place. template
- // and backupMax can be set in .jalview_properties
String dir = "";
File dirFile;
try