()
| 54 | } |
| 55 | |
| 56 | func ExampleRepositoriesService_ListByUser() { |
| 57 | client, err := github.NewClient() |
| 58 | if err != nil { |
| 59 | log.Fatalf("Error creating GitHub client: %v", err) |
| 60 | } |
| 61 | |
| 62 | user := "willnorris" |
| 63 | opt := &github.RepositoryListByUserOptions{Type: "owner", Sort: "updated", Direction: "desc"} |
| 64 | |
| 65 | ctx := context.Background() |
| 66 | repos, _, err := client.Repositories.ListByUser(ctx, user, opt) |
| 67 | if err != nil { |
| 68 | log.Fatalf("error listing repositories by user: %v", err) |
| 69 | } |
| 70 | |
| 71 | fmt.Printf("Recently updated repositories by %q: %v", user, github.Stringify(repos)) |
| 72 | } |
| 73 | |
| 74 | func ExampleRepositoriesService_CreateFile() { |
| 75 | // In this example we're creating a new file in a repository using the |
nothing calls this directly
no test coverage detected
searching dependent graphs…