public function create($user, $repo, $tagName, $targetCommitish = '', $name = '', $body = '', $draft = false, $preRelease = false)
	{
		// Build the request path.
		$path = '/repos/' . $user . '/' . $repo . '/releases';

		// Build the request data.
		$data = json_encode(
			array(
				'tag_name' => $tagName,
				'target_commitish' => $targetCommitish,
				'name' => $name,
				'body' => $body,
				'draft' => (boolean) $draft,
				'prerelease' => (boolean) $preRelease,
			)
		);

		// Send the request.
		return $this->processResponse($this->client->post($this->fetchUrl($path), $data), 201);
	}
public function create($user, $repo, $tagName, $targetCommitish = '', $name = '', $body = '', $draft = false, $preRelease = false)
	{
		// Build the request path.
		$path = '/repos/' . $user . '/' . $repo . '/releases';

		// Build the request data.
		$data = json_encode(
			array(
				'tag_name' => $tagName,
				'target_commitish' => $targetCommitish,
				'name' => $name,
				'body' => $body,
				'draft' => (boolean) $draft,
				'prerelease' => (boolean) $preRelease,
			)
		);

		// Send the request.
		return $this->processResponse($this->client->post($this->fetchUrl($path), $data), 201);
	}
public function create ( $ user , $ repo , $ tagName , $ targetCommitish = '' , $ name = '' , $ body = '' , $ draft = false , $ preRelease = false ) { // Build the request path. $ path = '/repos/' . $ user . '/' . $ repo . '/releases' ; // Build the request data. $ data = json_encode ( array ( 'tag_name' => $ tagName , 'target_commitish' => $ targetCommitish , 'name' => $ name , 'body' => $ body , 'draft' => ( boolean ) $ draft , 'prerelease' => ( boolean ) $ preRelease , ) ) ; // Send the request. return $ this -> processResponse ( $ this -> client -> post ( $ this -> fetchUrl ( $ path ) , $ data ) , 201 ) ; }
Method to create a release.

@param   string   $user             The name of the owner of the GitHub repository.
@param   string   $repo             The name of the GitHub repository.
@param   string   $tagName          The name of the tag.
@param   string   $targetCommitish  The commitish value that determines where the Git tag is created from.
@param   string   $name             The branch (or git ref) you want your changes pulled into. This
should be an existing branch on the current repository. You cannot
submit a pull request to one repo that requests a merge to a base
of another repo.
@param   string   $body             Text describing the contents of the tag.
@param   boolean  $draft            True to create a draft (unpublished) release, false to create a published one.
@param   boolean  $preRelease       True to identify the release as a prerelease. false to identify the release as a full release.

@return  object

@link    http://developer.github.com/v3/repos/releases/#create-a-release
@since   __DEPLOY_VERSION__
Method to create a release .