Description Usage Arguments Details Value Examples
This function creates a new project in GitHub. The project will be empty so you will need to add columns and cards separately.
1 | create_project(name, body, repo, org, ...)
|
name |
(string) The name of the project. |
body |
(string) The description of the project. |
repo |
(string, optional) The repository specified in the format:
|
org |
(string, optional) The name of the organization. |
... |
Parameters passed to |
You can create a project associated with either a repository or organization, by supplying them as an input, as long as you have appropriate permissions. If no repository or organization is specified the project is created for the authenticated user.
For more details see the GitHub API documentation:
https://docs.github.com/en/rest/reference/projects#create-a-repository-project
https://docs.github.com/en/rest/reference/projects#create-an-organization-project
https://docs.github.com/en/rest/reference/projects#create-a-user-project
create_project()
returns a list of the project properties.
Project Properties:
id: The ID of the project.
number: The number of the project for the repository, user or organization.
name: The name given to the project.
body: The description given to the project.
state: Whether the project is "open" or "closed".
private: Whether the project is private (organisation project only).
org_permission: The default permission for the project - either "read", "write" or "admin" (organisation project only).
creator: The user who created the project.
created_at: When it was created.
updated_at: When it was last updated.
html_url: The URL to view the project.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ## Not run:
# Create a project for a repository
create_project(
name = "Repo project",
body = "This is a repository's project",
repo = "ChadGoymer/githapi"
)
# Create a project for the current user
create_project(
name = "User project",
body = "This is a user's project"
)
# Create a project for an organization
create_project(
name = "Organization project",
body = "This is an organization's project",
org = "HairyCoos"
)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.