logging: pt1

This commit is contained in:
Ettore Di Giacinto
2024-04-15 00:13:10 +02:00
parent ac8f6e94ff
commit f0bc2be678
14 changed files with 118 additions and 126 deletions

View File

@@ -3,6 +3,7 @@ package external
import (
"context"
"fmt"
"log/slog"
"strings"
"github.com/google/go-github/v61/github"
@@ -52,7 +53,7 @@ func (g *GithubIssuesLabeler) Run(params action.ActionParams) (string, error) {
labels, _, err := g.client.Issues.AddLabelsToIssue(g.context, result.Owner, result.Repository, result.IssueNumber, []string{result.Label})
//labelsNames := []string{}
for _, l := range labels {
fmt.Println("Label added:", l.Name)
slog.Info("Label added:", l.Name)
//labelsNames = append(labelsNames, l.GetName())
}