diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-07-27 18:24:38 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-07-27 18:24:38 +0900 |
| commit | 95aa7c205ccff964ddd2302b8639a4853864e780 (patch) | |
| tree | ccb63b42924e77ea2b3d04822d86b2ae844c5e24 /internal/rosa/git.go | |
| parent | bd0cc3656f117093548d964b2868aa6f7e7d5d42 (diff) | |
internal/rosa: remove calls to low-level exec helper
This method predates the helper infrastructure, it is awkward to use and difficult to maintain for the replacement bootstrap mechanism. This change prepares for its removal.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/git.go')
| -rw-r--r-- | internal/rosa/git.go | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/internal/rosa/git.go b/internal/rosa/git.go index d4d679ba..a1bd8e0d 100644 --- a/internal/rosa/git.go +++ b/internal/rosa/git.go @@ -17,22 +17,29 @@ func (t Toolchain) NewViaGit( url, rev string, checksum pkg.Checksum, ) pkg.Artifact { - return t.New(strings.TrimSuffix( + return t.NewPackage(strings.TrimSuffix( path.Base(url), ".git", - )+"-src-"+path.Base(rev), THostNet, t.Append(nil, - _nssCACert, - _git, - ), &checksum, nil, ` + )+"-src", path.Base(rev), nil, &PackageAttr{ + KnownChecksum: &checksum, + + Flag: THostNet, + Paths: []pkg.ExecPath{resolvconf()}, + }, &GenericHelper{ + Build: ` git \ -c advice.detachedHead=false \ clone \ --depth=1 \ - --revision=`+rev+` \ + --revision=` + rev + ` \ --shallow-submodules \ --recurse-submodules \ - `+url+` \ + ` + url + ` \ /work rm -rf /work/.git -`, resolvconf()) +`, + }, + _nssCACert, + _git, + ) } |
