FreeCAD/FreeCAD

Core: Add incremental save option

Open

#27.318 aperta il 2 feb 2026

Vedi su GitHub
 (4 commenti) (2 reazioni) (0 assegnatari)C++ (5550 fork)batch import
Good first issueMod: CoreStatus: In Fork / Addon availableType: Feature

Metriche repository

Star
 (30.913 star)
Metriche merge PR
 (Merge medio 24g 7h) (217 PR mergiate in 30 g)

Descrizione

Problem description

Feature request: add incremental save option in the File menu, possibly with a commonly used shortcut if available (Blender defaults to Ctrl + Alt + S).

Example behavior from Blender, each row is a base > incremental save > incremental save chain:

"name"              > "name1"           > "name2"
"name "             > "name 1"          > "name 2"
"name 1 suffix"     > "name 2 suffix"   > "name 3 suffix"
"name1suffix"       > "name2suffix"     > "name3suffix"
"name 1 infix 1"    > "name 1 infix 2"  > "name 1 infix 3"
"name v1 infix 1"   > "name v1 infix 2" > "name v1 infix 3"
"name 09"           > "name 10" > ...   > "name 99" > "name 100"
"name 008"          > "name 009"        > "name 010"
"name 1"        ("name 2" exists)       > "name 3"
"a 1 b 2 c 3 d"     > "a 1 b 2 c 4 d"
"a1b2c3d"           > "a1b2c4d"

Pseudo-algo, as far as I can tell:

  • respect spacing (or lack thereof)
  • append 1 without any space if there's no number anywhere (but see other steps below about existing filenames)
  • if there's a number anywhere, increase it respecting the position in the filename
  • if there's more than one number, use the last one
  • if the number is prefixed by zeroes, consume one of such prefixed zeroes when you need to use higher unit positions
  • if a file with the candidate incremental name exists already, further increase the number and use that if available, without any prompts or warning, keep increasing according to the above algo until the candidate filename isn't found in the filesystem

Workbench affected?

None

Steps to reproduce

not relevant

Expected behavior

not relevant

Actual behavior

not relevant

Development version About Info (in Safe Mode)

not relevant

Last known good version (optional)

not relevant

Guida contributor