-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.go
42 lines (34 loc) · 1.08 KB
/
main.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
// Package main provides the entry point for the compatibility-user-acceptance tool.
// This tool validates compatibility of GraphQL implementations against graphql-js
// by comparing various GitHub repository metrics.
package main
import (
"fmt"
"log"
"net/http"
"github.com/graphql-go/compatibility-base/config"
"github.com/graphql-go/compatibility-user-acceptance/extractor"
)
// main is the entry point of the application. It initializes the extractor,
// fetches repository metrics from GitHub, and displays the results.
func main() {
// Load configuration.
cfg := config.Config{}
// Create a new extractor instance.
ex := extractor.New()
// Configure extraction parameters for the graphql-go/graphql repository.
params := extractor.RunParams{
HTTPClient: &http.Client{},
Organization: "graphql-go",
RepositoryName: "graphql",
}
// Run the extractor to fetch repository metrics.
r, err := ex.Run(¶ms)
if err != nil {
log.Fatal(err)
}
// Display debug information if enabled.
fmt.Println(cfg.IsDebug)
// Display the extraction results.
fmt.Printf("%+v\n", r)
}