ST6RI-865 Update repository save utilities by seidewitz · Pull Request #670 · Systems-Modeling/SysML-v2-Pilot-Implementation

This PR makes a small update to the KerMLRepositorySaveUtil, additionally to the updates already made for the new capabilities in PR #633.

The new capabilities in PR #633 included adding the -p option for an explicit project name to which to save a model. If this option is not used, then a default project name is created based on the file name of the model being saved. As implemented in PR #633, KerMLRepositorySaveUtil also still added the project creation timestamp to this default name, which is not consistent with the corresponding implementation of the Jupyter %publish command. The update in this PR is to remove the appending of the timestamp to the default project name.

As updated, the default project name is now just the model file name with the extension part removed. The extension part is considered to be that part of the file name from the last dot character (.) in the file name (if any) to the end of the file name. (Previously the computation used the first dot character, rather than the last, which incorrectly handled file names that included dots before the extension part.)