Revert "feat: cctuip lands in main"

See toolshed/abra#691 (comment)
This commit is contained in:
2025-10-17 19:27:23 +02:00
parent fc16a21f1c
commit 5b504a1550
8 changed files with 399 additions and 476 deletions

View File

@ -13,6 +13,7 @@ import (
"strings"
"coopcloud.tech/abra/pkg/i18n"
"github.com/go-git/go-git/v5"
"coopcloud.tech/abra/pkg/catalogue"
"coopcloud.tech/abra/pkg/config"
@ -169,6 +170,12 @@ func Get(name string) Recipe {
AbraShPath: path.Join(dir, "abra.sh"),
}
dirty, err := r.IsDirty()
if err != nil && !errors.Is(err, git.ErrRepositoryNotExists) {
log.Fatal(i18n.G("failed to check git status of %s: %s", r.Name, err))
}
r.Dirty = dirty
return r
}
@ -176,6 +183,7 @@ type Recipe struct {
Name string
EnvVersion string
EnvVersionRaw string
Dirty bool // NOTE(d1): git terminology for unstaged changes
Dir string
GitURL string
SSHURL string
@ -190,6 +198,7 @@ type Recipe struct {
func (r Recipe) String() string {
out := i18n.G("{name: %s, ", r.Name)
out += i18n.G("version : %s, ", r.EnvVersion)
out += i18n.G("dirty: %v, ", r.Dirty)
out += i18n.G("dir: %s, ", r.Dir)
out += i18n.G("git url: %s, ", r.GitURL)
out += i18n.G("ssh url: %s, ", r.SSHURL)