Description Usage Arguments Details Value Examples
view_repositories()
summarises the repositories for a user, team or
organization in a table with the properties as columns and a row for each
repository. view_repository()
returns a list of a single repository's
properties. browse_repository()
opens the web page for the repository in
the default browser.
1 2 3 4 5 6 7 8 9 10 11 12 13 | view_repositories(
user,
team,
org,
sort = "created",
direction = "desc",
n_max = 1000,
...
)
view_repository(repo, team, org, ...)
browse_repository(repo, ...)
|
user |
(string, optional) The login of the user. |
team |
(string, optional) The team name. |
org |
(string, optional) The name of the organization. |
sort |
(string, optional) The property to order the returned
repositories by. Can be either |
direction |
(string, optional) The direction of the sort. Can be either
|
n_max |
(integer, optional) Maximum number to return. Default: |
... |
Parameters passed to |
repo |
(string) The repository specified in the format: |
You can summarise all the repositories associated with either a user, team or organization, by supplying them as an input. If neither a user or organization is specified a summary of the authenticated user's repositories is returned.
For more details see the GitHub API documentation:
https://docs.github.com/en/rest/reference/repos#list-repositories-for-the-authenticated-user
https://docs.github.com/en/rest/reference/repos#list-repositories-for-a-user
https://docs.github.com/en/rest/reference/repos#list-organization-repositories
https://docs.github.com/en/rest/reference/teams#list-team-repositories
https://docs.github.com/en/rest/reference/repos#get-a-repository
view_repositories()
returns a tibble of repository properties.
view_repository()
returns a list of properties for a single repository.
browse_repository()
opens the default browser on the repository's page
and returns the URL.
Repository Properties:
id: The ID of the repository.
name: The name of the repository.
full_name: The full name of the repository, in the format:
owner/repo
.
description: The description of the repository.
owner: The owner of the repository.
html_url: The address of the repository's web page in GitHub.
homepage: The homepage for the repository.
language: The dominant programming language in the repository.
size: The overall size of the repository in bytes.
default_branch: The name of the default branch.
permission: The permission the authenticated user or team has.
private: Whether the repository is private.
has_issues: Whether the repository has issues.
has_projects: Whether the repository has projects.
has_wiki: Whether the repository has a wiki.
has_pages: Whether the repository has GitHub Pages.
has_downloads: Whether the repository has downloads.
allow_squash_merge: Whether the repository allows squash-merging pull requests.
allow_merge_commit: Whether the repository allows merging pull requests with a merge commit.
allow_rebase_merge: Whether the repository allows rebase-merging pull requests.
fork: Whether the repository is a fork of another.
archived: Whether the repository has been archived.
disabled: Whether the repository has been disabled.
watchers_count: The number of watchers.
stargazers_count: The number of stars.
forks_count: The number of forks.
pushed_at: When the repository was last pushed to.
created_at: When the repository was created.
updated_at: When the repository was last updated.
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 | ## Not run:
# View a user's repositories
view_repositories(user = "ChadGoymer")
# View an organization's repositories
view_repositories(org = "HairyCoos")
# View a team's repositories
view_repositories(team = "Test Team", org = "HairyCoos")
# Reorder a user's repositories
view_repositories(
user = "ChadGoymer",
sort = "full_name",
direction = "asc"
)
# View a specific user repository
view_repository("Test repo", user = "ChadGoymer")
# View a specific organization repository
view_repository("Test repo", org = "HairyCoos")
# View a specific team repository
view_repository("Test repo", team = "Test Team", org = "HairyCoos")
# Browse a specific user repository
browse_repository("Test repo", user = "ChadGoymer")
# Browse a specific organization repository
browse_repository("Test repo", org = "HairyCoos")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.