Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

8
LINES

< > BotCompany Repo | #1031050 // restoreNextToLastConceptsBackup

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (4320L/26K).

1  
svoid restoreNextToLastConceptsBackup(S dbID, O... _) {
2  
  bool doIt = boolPar doIt(_);
3  
  File file = conceptsFile(dbID);
4  
  backupFile(file);
5  
  File backup = nextToLast(sortByFileName(conceptBackupFiles(dbID)));
6  
  if (backup == null) ret with print("No usable backup found :(");
7  
  restoreConceptsBackup(dbID, backup, doIt);
8  
}

Author comment

Began life as a copy of #1022129

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1031050
Snippet name: restoreNextToLastConceptsBackup
Eternal ID of this version: #1031050/1
Text MD5: 5a3c6c3088dca668cabebac0f0b11915
Transpilation MD5: d9a2f7ef85026b6ca2f61466c19ca690
Author: stefan
Category: javax / concepts
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-04-26 15:44:40
Source code size: 331 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 190 / 290
Referenced in: [show references]