class Github::GitData::References
def update(user_name, repo_name, ref, params={})
"force" => true
"sha" => "827efc6d56897b048c772eb4087f854f46256132",
github.git_data.references.update 'user-name', 'repo-name', 'heads/master',
github = Github.new
= Examples
* :force - Boolean indicating whether to force the update or to make sure the update is a fast-forward update. The default is false, so leaving this out or setting it to false will make sure you’re not overwriting work.
* :sha - String of the SHA1 value to set this reference to
= Inputs
Update a reference
def update(user_name, repo_name, ref, params={}) _update_user_repo_params(user_name, repo_name) _validate_user_repo_params(user, repo) unless user? && repo? _validate_presence_of ref _validate_reference ref _normalize_params_keys(params) _filter_params_keys(VALID_REF_PARAM_NAMES, params) _validate_inputs(%w[ sha ], params) patch_request("/repos/#{user}/#{repo}/git/refs/#{ref}", params) end