pub enum GitHubResource {
File {
owner: String,
repo: String,
reference: String,
path: String,
},
Release {
owner: String,
repo: String,
tag: String,
name: String,
},
}Expand description
GitHub resource types
Variants§
File
Raw file in a repository Format: owner/repo/reference/path reference can be: branch name, tag, commit hash, or refs/heads/branch
Release
Release asset Format: owner/repo/tag/filename
Implementations§
Source§impl GitHubResource
impl GitHubResource
Sourcepub fn file(
owner: String,
repo: String,
reference: String,
path: String,
) -> Self
pub fn file( owner: String, repo: String, reference: String, path: String, ) -> Self
Create a new file resource
§Arguments
owner- Repository ownerrepo- Repository namereference- Git reference (branch, tag, commit hash, or refs/heads/branch)path- File path in the repository
Trait Implementations§
Source§impl Clone for GitHubResource
impl Clone for GitHubResource
Source§fn clone(&self) -> GitHubResource
fn clone(&self) -> GitHubResource
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GitHubResource
impl Debug for GitHubResource
Source§impl Hash for GitHubResource
impl Hash for GitHubResource
Source§impl IntoEnumIterator for GitHubResource
impl IntoEnumIterator for GitHubResource
Source§impl PartialEq for GitHubResource
impl PartialEq for GitHubResource
impl Eq for GitHubResource
impl StructuralPartialEq for GitHubResource
Auto Trait Implementations§
impl Freeze for GitHubResource
impl RefUnwindSafe for GitHubResource
impl Send for GitHubResource
impl Sync for GitHubResource
impl Unpin for GitHubResource
impl UnwindSafe for GitHubResource
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more