View Source Tentacat.References (Tentacat v2.5.0)
Summary
Functions
Create a Reference.
Get a Reference.
Get all References.
Delete a Reference.
Update a Reference.
Functions
@spec create(Tentacat.Client.t(), binary(), binary(), map()) :: Tentacat.response()
Create a Reference.
Reference body example:
%{
"ref" => "refs/heads/emj-otp-18",
"sha" => "aa218f56b14c9653891f9e74264a383fa43fefbd"
}
Example
Tentacat.References.create client, "elixir-lang", "elixir", ref_body
More info at: https://developer.github.com/v3/git/refs/#create-a-reference
@spec find(Tentacat.Client.t(), binary(), binary(), binary()) :: Tentacat.response()
Get a Reference.
Example
Tentacat.References.find "elixir-lang", "elixir", "heads/emj-otp-18"
Tentacat.References.find client, "elixir-lang", "elixir", "heads/emj-otp-18"
More info at: https://developer.github.com/v3/git/refs/#get-a-reference
@spec list(Tentacat.Client.t(), binary(), binary()) :: Tentacat.response()
Get all References.
Example
Tentacat.References.list "elixir-lang", "elixir"
Tentacat.References.list client, "elixir-lang", "elixir"
More info at: https://developer.github.com/v3/git/refs/#get-all-references
@spec remove(Tentacat.Client.t(), binary(), binary(), binary()) :: Tentacat.response()
Delete a Reference.
Example
Tentacat.References.remove client, "elixir-lang", "elixir", "heads/emj-otp-18"
Tentacat.References.remove client, "elixir-lang", "elixir", "tags/v1.0.2"
More info at: https://developer.github.com/v3/git/refs/#delete-a-reference
@spec update(Tentacat.Client.t(), binary(), binary(), binary(), map()) :: Tentacat.response()
Update a Reference.
Reference body example:
%{
"sha" => "aa218f56b14c9653891f9e74264a383fa43fefbd",
"force" => true
}
Example
Tentacat.References.update client, "elixir-lang", "elixir", "heads/emj-otp-18", body
More info at: https://developer.github.com/v3/git/refs/#update-a-reference