Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ KAI support. #129

Merged
merged 1 commit into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func main() {
if err != nil {
return
}

addon.Activity("Done.")

return
Expand Down Expand Up @@ -151,6 +151,12 @@ func updateApplication(d *Data, appId uint, issues *builder.Issues, deps *builde
appAnalysis := addon.Application.Analysis(appId)
mark := time.Now()
analysis := &api.Analysis{}
if d.Mode.Repository != nil {
analysis.Commit, err = d.Mode.Repository.Head()
if err != nil {
return
}
}
err = appAnalysis.Create(
analysis,
binding.MIMEYAML,
Expand Down
8 changes: 3 additions & 5 deletions cmd/mode.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,16 +70,14 @@ func (r *Mode) fetchRepository(application *api.Application) (err error) {
application.Repository.URL),
".")[0])
r.path.appDir = path.Join(SourceDir, application.Repository.Path)
var rp repository.SCM
rp, nErr := repository.New(
r.Repository, err = repository.New(
SourceDir,
application.Repository,
application.Identities)
if nErr != nil {
err = nErr
if err != nil {
return
}
err = rp.Fetch()
err = r.Repository.Fetch()
return
}

Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,13 @@ go 1.20
require (
github.com/gin-gonic/gin v1.9.1
github.com/konveyor/analyzer-lsp v0.4.0-alpha.1.0.20240603131628-bc4ff29956a2
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240729193114-3762bf20a313
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240813152219-3153a61e7c46
github.com/konveyor/tackle2-hub v0.5.0-rc.1.0.20240726125502-8bb3c0911660
github.com/onsi/gomega v1.27.6
github.com/rogpeppe/go-internal v1.10.0
go.lsp.dev/uri v0.3.0
gopkg.in/yaml.v2 v2.4.0
gopkg.in/yaml.v3 v3.0.1
k8s.io/utils v0.0.0-20220728103510-ee6ede2d64ed
)

Expand Down Expand Up @@ -99,7 +100,6 @@ require (
google.golang.org/grpc v1.62.1 // indirect
google.golang.org/protobuf v1.33.1-0.20240408130810-98873a205002 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
gorm.io/gorm v1.25.2-0.20230530020048-26663ab9bf55 // indirect
k8s.io/api v0.25.0 // indirect
k8s.io/apimachinery v0.25.0 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZX
github.com/klauspost/cpuid/v2 v2.2.4/go.mod h1:RVVoqg1df56z8g3pUjL/3lE5UfnlrJX8tyFgg4nqhuY=
github.com/konveyor/analyzer-lsp v0.4.0-alpha.1.0.20240603131628-bc4ff29956a2 h1:jASTTOXjewf2qWDAqc4pqNrIC3g7r9BLvJeoXaOBogU=
github.com/konveyor/analyzer-lsp v0.4.0-alpha.1.0.20240603131628-bc4ff29956a2/go.mod h1:GXkSykQ84oE1SyMvFko9s9wRn/FMdl4efLLWSjMX2nU=
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240729193114-3762bf20a313 h1:UbXOpQgmvpAWMNJGA8XSEWDWph+kpahhWC1MIsY676M=
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240729193114-3762bf20a313/go.mod h1:1cHTnmMGtYzv0GIMiyEMPkJe+hOlzbhxwRal5e7Mog0=
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240813152219-3153a61e7c46 h1:cHLMtHTCiFxYNMejsZvhFTuByjipjlm/5Zt5+hdYRVY=
github.com/konveyor/tackle2-addon v0.5.0-rc.2.0.20240813152219-3153a61e7c46/go.mod h1:1cHTnmMGtYzv0GIMiyEMPkJe+hOlzbhxwRal5e7Mog0=
github.com/konveyor/tackle2-hub v0.5.0-rc.1.0.20240726125502-8bb3c0911660 h1:joaeY9ndWjNd6rgwyhoa+lgcIRiNwvAcR9LWQvAyN10=
github.com/konveyor/tackle2-hub v0.5.0-rc.1.0.20240726125502-8bb3c0911660/go.mod h1:5c5A3i/oARdUp1yo+iYJFFvsIlsbsVGBZT7/CQji9YY=
github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
Expand Down
Loading