create_issue: Create an issue in a repository

Description Usage Arguments Details Value Examples

View source: R/issues.R

Description

This function creates a new issue for the specified repository in GitHub. It can also be used to assign the issue to a user and add labels or a milestone.

Usage

1
create_issue(title, repo, body, assignees, labels, milestone, ...)

Arguments

title

(string) The title of the issue.

repo

(string) The repository specified in the format: owner/repo.

body

(string, optional) The contents of the issue.

assignees

(character, optional) Logins for Users to assign to this issue. NOTE: Only users with push access can set assignees for new issues.

labels

(character, optional) Labels to associate with this issue. NOTE: Only users with push access can set labels for new issues.

milestone

(character or integer, optional) The title or number of the milestone to associate this issue with. NOTE: Only users with push access can set the milestone for new issues.

...

Parameters passed to gh_request().

Details

For more details see the GitHub API documentation:

Value

create_issue() returns a list of the issue's properties.

Issue Properties:

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## Not run: 

  create_issue(
    title     = "user issue",
    repo      = "ChadGoymer/test-issues",
    body      = "This is an issue to test create_issue()",
    assignees = "ChadGoymer",
    labels    = "feature",
    milestone = "release-1.0"
  )

  create_issue(
    title     = "organization issue",
    repo      = "HairyCoos/test-issues",
    body      = "This is an issue to test create_issue()",
    assignees = "ChadGoymer"
  )


## End(Not run)

ChadGoymer/githapi documentation built on Oct. 22, 2021, 10:56 a.m.