feat: pull request generation
This commit is contained in:
18
internal/setup/pullrequest_handler.go
Normal file
18
internal/setup/pullrequest_handler.go
Normal file
@ -0,0 +1,18 @@
|
||||
package setup
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"forge.cadoles.com/wpetit/clearcase/internal/config"
|
||||
"forge.cadoles.com/wpetit/clearcase/internal/http/handler/webui/pullrequest"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
func NewPullRequestHandlerFromConfig(ctx context.Context, conf *config.Config) (*pullrequest.Handler, error) {
|
||||
forgeManager, err := NewForgeManagerFromConfig(ctx, conf)
|
||||
if err != nil {
|
||||
return nil, errors.WithStack(err)
|
||||
}
|
||||
|
||||
return pullrequest.NewHandler(forgeManager), nil
|
||||
}
|
Reference in New Issue
Block a user