Исправление дублирования "alr" в названии пакета
All checks were successful
Pre-commit / pre-commit (push) Successful in 5m6s
Create Release / changelog (push) Successful in 3m7s

This commit is contained in:
2025-09-21 13:43:36 +03:00
parent 7b9404a058
commit 42f0d5e575

View File

@@ -176,8 +176,13 @@ func getBasePkgInfo(vars *alrsh.Package, input interface {
OsInfoProvider
},
) *nfpm.Info {
repo := input.Repository()
// Избегаем дублирования "alr-" префикса
if strings.HasPrefix(repo, "alr-") {
repo = repo[4:] // убираем "alr-" префикс
}
return &nfpm.Info{
Name: fmt.Sprintf("%s+alr-%s", vars.Name, input.Repository()),
Name: fmt.Sprintf("%s+alr-%s", vars.Name, repo),
Arch: cpu.Arch(),
Version: vars.Version,
Release: overrides.ReleasePlatformSpecific(vars.Release, input.OSRelease()),