fix: unstaged changes handling

See toolshed/organising#651
This commit is contained in:
2024-12-31 11:19:03 +01:00
parent bfed51a69c
commit 5975be6870
26 changed files with 622 additions and 56 deletions

View File

@ -182,7 +182,7 @@ beforehand.`,
if err != nil {
log.Fatal(err)
}
for _, version := range versions {
for _, version := range internal.SortVersionsDesc(versions) {
parsedVersion, err := tagcmp.Parse(version)
if err != nil {
log.Fatal(err)
@ -289,7 +289,6 @@ beforehand.`,
}
app.Recipe.Version = chosenUpgrade
log.Debugf("choosing %s as version to save to env file", app.Recipe.Version)
if err := app.WriteRecipeVersion(app.Recipe.Version, false); err != nil {
log.Fatalf("writing new recipe version in env file: %s", err)
}