Libraryless. Click here for Pure Java version (5143L/28K).
static File makeFileNameUnique_beforeExtension_startWith1_noDot(File f) { File orig = f; int n = 1; do { f = appendToFileBaseName(orig, str(n++)); } while (f.exists()); ret f; }
Began life as a copy of #1033396
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
| Snippet ID: | #1033850 | 
| Snippet name: | makeFileNameUnique_beforeExtension_startWith1_noDot | 
| Eternal ID of this version: | #1033850/3 | 
| Text MD5: | 1710d589e24c2bf4cbb31df84b03aab5 | 
| Transpilation MD5: | f6664837458a2b0f3223c1b24c8be914 | 
| Author: | stefan | 
| Category: | javax / io | 
| Type: | JavaX fragment (include) | 
| Public (visible to everyone): | Yes | 
| Archived (hidden from active list): | No | 
| Created/modified: | 2022-01-07 01:24:40 | 
| Source code size: | 198 bytes / 8 lines | 
| Pitched / IR pitched: | No / No | 
| Views / Downloads: | 389 / 504 | 
| Version history: | 2 change(s) | 
| Referenced in: | [show references] |